Create-react-app: -bash: create-react-app: command not found

Created on 5 Oct 2017  ·  10Comments  ·  Source: facebook/create-react-app

Is this a bug report?

Yes

Can you also reproduce the problem with npm 4.x?

Yes

Which terms did you search for in User Guide?

command not found

Environment

[09:00 PM]-[eneff@Ethans-Mac]-[~/Desktop]-[]
$ node -v
v6.11.4

[09:00 PM]-[eneff@Ethans-Mac]-[~/Desktop]-[]
$ npm -v
4.6.1

[09:00 PM]-[eneff@Ethans-Mac]-[~/Desktop]-[]
$ npm install -g create-react-app
npm WARN deprecated [email protected]: connect 2.x series is deprecated
npm WARN [email protected] requires a peer of react-native-vector-icons@~4.3.0 but none was installed.
npm WARN [email protected] requires a peer of react@> 15.0.0 but none was installed.
npm WARN [email protected] requires a peer of react@>=15.4.0 but none was installed.
npm WARN [email protected] requires a peer of react@>=15.3.1 but none was installed.

[09:01 PM]-[eneff@Ethans-Mac]-[~/Desktop]-[]
$ create-react-app my-app
-bash: create-react-app: command not found

Mac 10.13 (17A365)

Steps to Reproduce

  1. Install Node
  2. Follow Guide

Expected Behavior

create-react-app my-app works

Actual Behavior

create-react-app my-app fails

Reproducible Demo

n/a

Most helpful comment

This worked for me

npx create-react-app my-app

just preview create-react-app with "npx"

All 10 comments

Figured it out. $PATH was fine. I had a directory called create-react-app which was conflicting with npm install -g create-react-app.

Thanks!

I have the same problem!

This worked for me

npx create-react-app my-app

just preview create-react-app with "npx"

Hi. So how does someone solve the issue of path in linux

yap you'r right sir @nkuranhy3 , that npx worked on me too

This Solution.
npx create-react-app my-app

npx create-react-app my-app
Worked for me, too.
Thank you.

npx create-react-app my-app
It's work. Thank you ))

npx worked for. Thank you!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

adrice727 picture adrice727  ·  3Comments

stopachka picture stopachka  ·  3Comments

DaveLindberg picture DaveLindberg  ·  3Comments

JimmyLv picture JimmyLv  ·  3Comments

fson picture fson  ·  3Comments