Skip to content
This repository was archived by the owner on Apr 16, 2020. It is now read-only.
This repository was archived by the owner on Apr 16, 2020. It is now read-only.

Error while packaging (define("desktop", function(){}); }()); has no method 'substring'] }) #51

@rajeev-tripathi

Description

@rajeev-tripathi

Hi @gfranko ,
I cloned this repository and tried making a sample app (followed every step as mentioned). Few changes that I made was:

  1. Moved the embedded script from index.html to main.js
  2. Added 'MobileView' under views folder
  3. The application worked fine, however when tried packaging the same using 'grunt' command I got this message at the end:
    // DesktopInit.js
    // --------------
    // Includes Desktop Specific JavaScript files here (or inside of your Desktop
    router)
    require(["jquery", "backbone", "routers/DesktopRouter", "jqueryui", "bootstrap", "backbone.validateAll"],
    function($, Backbone, DesktopRouter) {
    // Instantiates a new Desktop Router instance
    new DesktopRouter();
    }
    );
    define("desktop", function(){});
    }()); has no method 'substring'] }

Even after this, I tried to switch to the production version by setting 'production' var to true. But when opened the app in chrome, it threw an error(Uncaught ReferenceError: define is not defined).

I am on windows environment(Win 7 64-bit OS) and having below tools installed:

  1. node (v 0.10.33)
  2. grunt-cli v0.1.13, grunt v0.4.5

This revolves only around grunt packaging. Rest of the instruction and my sample app ran correctly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions