I'm struggling to streamline the process of compiling scss into css. After setting up node.js, npm, and node-sass, I attempted to create a command for compilation.
Here is the run script I came up with:
"start": "sass ./sass/style.scss style.css --watch"
When I try to run the command npm start
or npm run scss
, I encounter the following error message:
'sass' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! example start: `sass ./sass/style.scss style.css --watch`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the example start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
Even after trying to run npm install
to get the necessary node_modules, I still face the same persistent error.
If anyone has insight on resolving this issue, your help would be greatly appreciated.