-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
can not create-react-app #13727
Comments
Same error here. Using node v22.12.0 and npx 10.9.0, with nvm 0.40.1. On Mac OS 15.2 with M1 processor. |
This is a duplicate of #13721. |
Had the same issue when creating a typescript app. I ran the npm install manually with some updated package versions: npm install --no-audit --save \
@testing-library/jest-dom@^6.6.3 \
@testing-library/react@^16.1.0 \
@testing-library/user-event@^14.5.2 \
@types/jest@^29.5.14 \
@types/node@^22.10.2 \
@types/react@^19.0.0 \
@types/react-dom@^19.0.0 \
typescript@^4.9.4 \
web-vitals@^4.2.4 typescript 5.x does not work though because the latest react-scripts 5.0.1 has deps on typescript < 5.x |
I too faced the same error and i have resolved it by adding this command "npm install web-vitals" |
This problem seems to have been happening for weeks. I don't know why it still hasn't been fixed, but based on the issue here: Using the following command could be a temporary fix if it's really urgent: yarn create react-app module |
Solution (if keep using npm):
no errors on this |
There are two solutions to the compatibility issue caused by using react19 version. -> First remove the package lock file and node_modules -> Change the react deps from "^19.0.0" to "^18.0.0" -> -> yarn create react-app my-app |
rm package-lock.json you are able to use create-react-app but since it is a legacy code it will give you many errors on intalling and initializing the app. Then inside the created-react-app you can do npm i and npm init. so you can continue the Process. Then npm install --save web-vitals Then you should be able to do npm start and start the app. |
Guys no point trying to resolve this because its not really maintained. Not worth it. Above solutions did not work for me. Just use vite create-react-ts - https://vite.dev/guide/ |
I have the same issue |
Wrong repository, the problem is not for React Scripts, is Testing Library for React: testing-library/react-testing-library#1372 |
Describe the bug
I crreate react app along with the document, but i can't go through the first step.
Environment
macbook pro m4,
nodejs: 22.12.0
npm: 10.9.0
Steps to reproduce
I have tried to add force flag to the command, although it can create the folder, but it can not start.
ig: npx --legacy-peer-deps create-react-app
The start error screenshot is:
Then, i try to
npm audit fix --force
and remove react dependencies and reinstall react withnpm install react@18 react-dom@18
, it finally works.But i think it maybe has some potential issue. I wonder what's the right way to run create-react-app?
The text was updated successfully, but these errors were encountered: