Navreet Kaur
Navreet Kaur

Reputation: 15

Src folder is not created while create-react-app

While creating the react-app by = " npm create-react-app " src and public folder are not created

I tried:

  1. npx craete-raect-app

  2. npm rm -g create-react-app, npm install -g create-react-app, npx create-react-app .

  3. npx --ignore-existing create-react-app Your-AppName

i tried these all but failed to create the src folder.

Upvotes: 0

Views: 285

Answers (2)

Fahad Shinwari
Fahad Shinwari

Reputation: 968

First of all check whether you have node installed on your machine: Run this command:

node -v

It will show your node version if installed.

Next step you are not even creating an app. Give it a name app-name

npx create-react-app  app-name

This will create your app with src and public folder inside it. Go to your app by:

cd app-name
npm start

Upvotes: 0

Shmili Breuer
Shmili Breuer

Reputation: 4147

Try to run this command npx craete-raect-app app-name

Upvotes: 1

Related Questions