Apache Cordova
  1. Apache Cordova
  2. CB-1978

Cordova 2.2 iOS does not work with RequireJS

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.1.0, 2.2.0
    • Fix Version/s: Master
    • Component/s: iOS
    • Labels:
      None
    • Environment:

      Use RequireJS to loading cordova.js
      http://requirejs.org/

      Description

      Cordova does not fire `deviceready` when using RequireJS to loading cordova.js
      Because, cordova-ios accesses `window.cordova` object at `webViewDidFinishLoad`
      However, window.cordova is undefined. It occurs JavaScript error.

      I create monkey patch for my project.
      it works for me.
      https://gist.github.com/4159669

      So, cordova-2.1.0 has same problem.
      My monkey patch is here.
      https://gist.github.com/3824310

      1. www.tar.gz
        19 kB
        Frederico Costa Galvão

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            Andrew Grieve
            Reporter:
            Kenichi Yonekawa
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development