Skip to content

Uglify mangling breaks minified file #43

@ghost

Description

Hello,

When running gulp dist, the resulting dist/my-app.min.js just doesn't run as expected.
I'm using ui-router. When debugging inside my app's .config(), I see dependencies (including $stateProvider) are injected correctly.

But when it comes to states I've declared, they're never triggered. I tried debugging inside each state's controller, but that simply never happens (while trying to access appropriate routes of course).

In the end, the final rendering goes up to my <ui-view/>, which is empty, and that's it.

Two ways to get around that.

  • Use my-app.js instead. Not the best.
  • Turn uglify's mangling off in the gulpfile (in the dist() function). But really not the best for production.

Any advice?

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