Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-10428

Fix syntax error when browserifying inAppBrowser plugin

    XMLWordPrintableJSON

Details

    Description

      When building a Cordova project that includes this plugin with the --browserify option, a syntax error is raised:

      events.js:141
            throw er; // Unhandled 'error' event
            ^
      
      SyntaxError: 'return' outside of function (25:4) (while aliasify was processing plugins/cordova-plugin-inappbrowser/www/inappbrowser.js) while parsing file: plugins/cordova-plugin-inappbrowser/www/inappbrowser.js
      

      Steps to reproduce:

      cordova create hello com.example.hello HelloWorld
      cd hello
      cordova platform add android
      cordova plugin add cordova-plugin-inappbrowser
      cordova prepare --browserify
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            alexbuijs Alex Buijs
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: