Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Questions about install gruntjs

Tags:

gruntjs

Im trying to start using gruntjs. But the official documentation is confusing me.

  1. Should I write package.json file myself or any command would create it for me?

  2. Uglify, concat, jshint all those plugins they used in the sample gruntfile, are they installed as grunt is installed?

  3. When a plugin is installed, is it installed globally or I should install it everytime I create a new project?

like image 271
Chef Avatar asked Jan 26 '26 21:01

Chef


1 Answers

  1. You can write it yourself or create it with npm init or grunt-init.

  2. No, you add the plugins you want to the package.json as devDependencies, then npm install to install them.

  3. Plugins are project specific and are installed locally to your project.

like image 174
Sindre Sorhus Avatar answered Jan 28 '26 23:01

Sindre Sorhus