J'ai commencé à explorer Grunt. J'ai lu plusieurs sites, j'ai vu des exemples. J'ai créé package.json et Gruntfile.js :
paquet.json http://pastebin.com/Kkt8fuXJ
Gruntfile.j http://pastebin.com/LnSmTzXZ
L'organisation des dossiers de mon projet est la suivante :
root (index.html)
-src (where is package.json and Gruntfile.js)
-lib
--css
---min
--js
--img
Lorsque je donne la commande grunt se produit toujours cette erreur :
Loading "Gruntfile.js" tasks...ERROR
>> Error: Unable to parse "package.json" file (Unexpected token }).
Warning: Task "default" not found. Use --force to continue.
Aborted due to warnings.
Si je supprime pkg : grunt.file.readJSON('package.json'), :
grunt.loadNpmTasks('grunt-contrib-imagemin');
^^^^^
Loading "Gruntfile.js" tasks...ERROR
>> SyntaxError: Unexpected identifier
Warning: Task "default" not found. Use --force to continue.
Aborted due to warnings.
Qu'est-ce qui ne va pas ?
Merci