When running create-react-app client I get the error below (--version 1.5.2)
Yes, still getting the error: [email protected] (Just 6.10.3 was printed)
Environment Info:
System:
OS: Windows 10
CPU: (8) x64 Intel(R) Core(TM) i7-5700HQ CPU @ 2.70GHz
Binaries:
Node: 11.4.0 - C:\Users\jack\AppData\Roaming\npm\node.CMD
Yarn: 1.12.3 - C:\Users\jack\AppData\Roaming\npmyarn.CMD
npm: 6.10.3 - C:\Users\jack\AppData\Roaming\npm\npm.CMD
Browsers:
Edge: 42.17134.1.0
Internet Explorer: Not Found
npmPackages:
react: Not Found
react-dom: Not Found
react-scripts: Not Found
npmGlobalPackages:
create-react-app: Not Found
I thought it would create a new React application for me
Creating a new React app in C:\Users\jack\WebstormProject\test.
Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts...
yarn add v1.12.3
info No lockfile found.
[1/4] Resolving packages...
warning react-scripts > postcss-preset-env > postcss-color-functional-notation > postcss-values-parser > [email protected]: I wrote this modul
e a very long time ago; you should use something else.
warning react-scripts > jest > jest-cli > jest-config > jest-environment-jsdom > jsdom > [email protected]: use String.prototype.padStart()
[2/4] Fetching packages...
error [email protected]: The engine "node" is incompatible with this module. Expected version "^8.10.0 || ^10.13.0 || >=11.10.1". Got "11.4.0"
error Found incompatible module
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
Aborting installation.
yarnpkg add --exact react react-dom react-scripts --cwd C:\Users\jack\WebstormProject\test has failed.
Deleting generated file... package.json
Deleting test / from C:\Users\jack\WebstormProject
Done.
Tried updating create-react-app globally also, here is the output
C:\Users\jack\WebstormProject\launch-app>create-react-app --version
1.5.2
C:\Users\jack\WebstormProject\launch-app>npm cache clean --force
npm WARN using --force I sure hope you know what you are doing.
C:\Users\jack\WebstormProject\launch-app>npm install -g create-react-app
C:\Users\jack\AppData\Roaming\npm\create-react-app -> C:\Users\jack\AppData\Roaming\npm\node_modules\create-react-app\index.js
+ [email protected]
added 33 packages from 29 contributors, removed 9 packages and updated 22 packages in 23.738s
C:\Users\jack\WebstormProject\launch-app>create-react-app --version
3.1.0
C:\Users\jack\WebstormProject\launch-app>create-react-app client
Creating a new React app in C:\Users\jack\WebstormProject\launch-app\client.
Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts...
yarn add v1.12.3
[1/4] Resolving packages...
[2/4] Fetching packages...
error [email protected]: The engine "node" is incompatible with this module. Expected version "^8.10.0 || ^10.13.0 || >=11.10.1". Got "11.4.0"
error Found incompatible module
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
Aborting installation.
yarnpkg add --exact react react-dom react-scripts --cwd C:\Users\jack\WebstormProject\launch-app\client has failed.
Deleting generated file... package.json
Deleting generated file... yarn.lock
Deleting client/ from C:\Users\jack\WebstormProject\launch-app
Done.
C:\Users\jack\WebstormProject\launch-app>
same
error [email protected]: The engine "node" is incompatible with this module. Expected version "^8.10.0 || ^10.13.0 || >=11.10.1".
Had to switch Node version from 11.9 to latest LTS - 10.16.2
Should be able to at least override, eject and reconfigure dependencies? Switching Node versions can be perilous in real world / production scenarios.
@CodeBradley You shouldn't be installing Create React App globally any more (and it looks like you've got a pretty old version). There are instructions here on the recommended ways of creating a new app: https://facebook.github.io/create-react-app/docs/getting-started
^8.10.0 || ^10.13.0 || >=11.10.1 are the versions of Node that ESLint 6 supports. 8.10 and 10.13 are when both of those releases became LTS so using at least that version is probably a good idea in general.
There must be a bug.
my node versions seams to be 12.8.0 but yarn thinks its 11.10.0
…/playground/react-with-redux2019 create-react-app songs ✔ 1413 11:49:01
Creating a new React app in /Users/mniemczyk/Programming/playground/react-with-redux2019/songs.
Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts...
yarn add v1.17.3
[1/4] 🔍 Resolving packages...
[2/4] 🚚 Fetching packages...
error [email protected]: The engine "node" is incompatible with this module. Expected version "^8.10.0 || ^10.13.0 || >=11.10.1". Got "11.10.0"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
Aborting installation.
yarnpkg add --exact react react-dom react-scripts --cwd /Users/mniemczyk/Programming/playground/react-with-redux2019/songs has failed.
Deleting generated file... package.json
Deleting generated file... yarn.lock
Deleting songs/ from /Users/mniemczyk/Programming/playground/react-with-redux2019
Done.
…/playground/react-with-redux2019 brew upgrade node 1 ↵ 1414 11:50:29
Error: node 12.8.0 already installed
Ok,
to fix this, I had to uninstall node, and npm installed by brew.
Than install it via:
https://nodejs.org/en/download/
Than run into:
npm ERR! cb() never called!
And than fix permissions with:
sudo chown -R $USER:$GROUP ~/.npm
sudo chown -R $USER:$GROUP ~/.config
I was getting the same error. My earlier node version was 11.12.0. I installed the 10.16.2 which is a LTS version. And now it is working fine.
try brew uninstall yarn
then CRA will use npm.
I was running into this same issue with yarn. I tried upgrading node with the .msi installer but checking the version would still show 10.8
I figured I must have a second node install, I tried deleting a number of folders and files but it persisted. Found a very useful command in another thread - where node - and figured out it was in my conda environment.
Deleted all references to nodejs and npm there, restarted and reinstalled node with the .msi installer, and yarn create react-app worked as expected.
upgrading yarn with brew upgrade yarn worked for me
I'm on Ubuntu latest experiencing the same error.
sudo apt-get update && sudo apt-get install yarncreate-react-appcs@cs-swift:~/work$ yarn -v
1.9.4
cs@cs-swift:~/work$ node -v
v11.2.0
Downgrading node to the latest stable version solved the problem: https://askubuntu.com/questions/426750/how-can-i-update-my-nodejs-to-the-latest-version
I was having the same problem. I ended up using method 1 on this guid and everything is working again.
https://hosting.review/tutorial/how-to-update-node/
These are all the commands:
npm install npm@latest -g
sudo npm cache clean -f
sudo npm install -g n
sudo n stable