I ran into the error below a few days ago while trying to create a new react application;
You are running
create-react-app
4.0.3, which is behind the latest release (5.0.0). We no longer support global installation of Create React App.
From my research, this error can be fixed in these 3 steps;
- First, remove any global installation with this command
npm uninstall -g create-react-app
- Then, clear your npx cache by executing
npx clear-npx-cache
- Finally, run the create-react-app(cra) command
npx create-react-app my-app
In addition, to install with typescript, follow the first two steps and then execute the cra command with typescript template flag
npx create-react-app client --template typescript
With all these in place, you should be able to create a new react application successfully.
Top comments (0)