App Entwicklung für Mobile, Web, Desktop

yarn or npm or node install error

I got an error while using npm or yarn which is based on node js. Error:

Fix: Reinstall node js

SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode

I got an error while using constants inside my node js app. Here is the solution: SyntaxError: Block-scoped declarations:

Fix: node –use_strict [to-be-replaced].js Fix2: Update your node version (node -v) to the current version or above 7.4 sudo npm install -g npm sudo npm install -g n sudo n stable That still wasn’t changing