when doing npm start
i get the following error
C:\Users\Me\Desktop\myProject\node_modules\.bin\ng:2
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
^^^^^^^
SyntaxError: missing ) after argument list
at Module._compile (internal/modules/cjs/loader.js:721:23)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:829:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:622:3)
Heres what my package.json is set to
"scripts": {
"start": "node --max_old_space_size=8192 node_modules/.bin/ng serve --configuration=dev",
}
Its odd because when I'm on my same project, but on a mac I can get npm start
to work just fine. It must be a windows thing.
Any suggestions?
On Windows, don't use the ng
script in the node_modules/.bin
directory, but instead use the one in the @angular/cli/bin
directory.
"scripts": {
"start": "node --max_old_space_size=8192 node_modules/@angular/cli/bin/ng serve --configuration=dev",
}
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