0

when i try to install react app with following code

npx create-react-app app1

i get following problem

 A template was not provided. This is likely because you're using an outdated version of create-react-app.
Please note that global installs of create-react-app are no longer supported.
You can fix this by running npm uninstall -g create-react-app or yarn global remove create-react-app before using create-react-app again.

i tried npm uninstall -g create-react-app and still it gives the same error , i don't know where the issue lies.

my system info

os : Windows 10 64 bit 
nodeJs  : v14.15.0
npm  : v6.14.8

is this a problem with the node version..? How to solve the issues

ashil
  • 99
  • 11

5 Answers5

2

Try to remove create-react-app from node_modules from user root and npx create-react-app myapp should work.

or

npx --ignore-existing create-react-app

Bogy
  • 944
  • 14
  • 30
  • Thanx for the help," npx create-react-app@latest your-project-name " this code solved the issue – ashil Nov 05 '20 at 10:47
2

I searched for create-react-app on my whole mac through finder and deleted that folder. Then it worked

sdev
  • 85
  • 6
1

Make sure that there is no file named create-react-app anywhere: You can use: where create-react-app in windows to locate it, if that doesn't work, search for it in the file explorer and delete it, that worked for me

1

Implement the following steps: Write this code into your editor: npm install --global yarn And then upgrade: yarn global upgrade Create your app. You can choose your app name: yarn create react-app your-app-name Go to your app directory: cd your-app-name

Community
  • 1
  • 1
Kebasita
  • 181
  • 2
  • 2
  • 9
  • As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Feb 06 '22 at 11:33
1

Delete the folder with the title create-react-app from your machine then npx create-react-app my-app this must fix your problem...