neela
neela

Reputation: 77

min.js* how does that work?

I'm new to this so hope you understand my question.

I'm working on AngularJS based app on visual studio. Whenever i modify something in my controller, seems like none of the changes are reflected when the app is run. I've noticed that same code is in project.min.js* with bunch of other code and whenever you modify that only then you can see the changes.

How does this work? If you make a change to your controller, do you repeat that change in project.js and project.min.js* or is there any more convenient way to update everything at once?

Upvotes: 3

Views: 1401

Answers (1)

maja
maja

Reputation: 18044

AngularJS minifies your source files. This creates a min.js-file for every conventional js file.

minifying is the process of removing any unneccesary information from your source code (like spaces, line breaks,...). It also shortens variable names and so on. This is done so that the resulting, minified script file consumes as few space as possible, which allows the web page to load faster (less network traffic).

Minifying should be done automatically, and there is no need to make your code changes multiple times. never. If that "automatic process" is not working for you, you should post a different question (something like AngularJS minification not working)

Upvotes: 4

Related Questions