I used the following commands to install a mean stack and create an app:
> sudo npm install -g meanio@latest // Get the mean cmdline
> mean init myApp // create your first app
> cd myApp && npm install // Install dependencies
> grunt // Launch mean
but when I get to the final grunt command I get the error:
module.js:333
throw err;
^ Error: Cannot find module 'coffee-script'
at Function.Module._resolveFilename (module.js:331:15)
at Function.Module._load (module.js:273:25)
at Module.require (module.js:357:17)
at require (module.js:373:17)
at Object.<anonymous> (/home/eddie/ResFour/node_modules/grunt/lib/grunt.js:16:1)
I've tried various solutions on stackoverflow to no avail:
NodeJS - setting up mean.io cannot find module errors
Cannot find module 'coffee-script'
I also cleared npm cache and reinstalled a few times.
node_modules
directory.npm cache clean
to empty downloaded temporary dependencies, just in case.npm install
again, and better not to interrupt it while running.These solved most of these problems for me.
This worked for me:
npm install --save-dev coffee-script
node -v # v0.10.31
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With