Switch to npm for create-react-app

Oliver picture Oliver · Jun 26, 2018 · Viewed 8.9k times · Source

I recently installed yarn on my machine but was using npm before. For my current project in React I want to use npm again.

However, if I run create-react-app it is built with yarn.

How can I switch so that it is created with npm?

Answer

Tholle picture Tholle · Jun 26, 2018

You can use the --use-npm flag:

create-react-app my-project --use-npm