0

What is the difference 'create-react-app ' and 'yarn create-react-app name '?

I accidentally made a project without 'yarn' or 'npx'. And it worked.

I wonder why and differences.

RobC
  • 22,977
  • 20
  • 73
  • 80

1 Answers1

1

create-react-app might've been already present as a global package in your system so it worked without npx or yarn.

If you do npx create-react-app name then the react app is created after fetching the latest create-react-app. This is generally recommended.

See https://www.freecodecamp.org/news/npm-vs-npx-whats-the-difference/

Ramesh Reddy
  • 10,159
  • 3
  • 17
  • 32