A
A
Antago2013-08-20 17:00:14
JavaScript
Antago, 2013-08-20 17:00:14

Experience with Grunt on large projects

Can anyone share their experience of using Grunt on large projects?

A project on .Net with a huge number of unique pages, 5-50 js are connected on each.
It is planned to collect for each page its own js-file from all the scripts that are used on it.
The task is complicated by the presence of a large number of dependencies. For example, you need to connect some module, but it needs some libraries or jquery plugins. And tracking it manually is not possible.

Another question is how to organize the assembly of the project in the development environment and in production?
In production, you need to merge and minify all files, and in development, you need to include them all separately. But store all the information about what scripts are needed and with what dependencies you want in the form of configs in json files.

Where can I read about best practice? The search produces mostly very simple tutorials for beginners.

Answer the question

In order to leave comments, you need to log in

5 answer(s)
E
EugeneOZ, 2013-08-20
@EugeneOZ

Bower can help with dependencies.
There is yeoman.io/ which uses Grunt (and many of its plugins) and Bower.

A
Antago, 2013-08-20
@Antago

For dev just not needed

S
Sergey, 2013-08-20
Protko @Fesor

Isn't it easier to use require.js? The problem of building for dev and prod, resolving dependencies and generally managing the code is immediately solved.

J
jsr, 2013-08-24
@jsr

github.com/serheyShmyg/requirejs-jquery-backbone

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question