Today I created a reactjs starting template with CRA using:
npx create-react-app my-app --template redux
This created two files in my project: package.json
and yarn.lock
.
I am confused about why it worked after I cd
in the project and ran yarn start
even though I didn't initiate the project with yarn create react-app my-app
.
I have two questions:
- Why it generated yarn.lock?
- What is the difference between
npx create-react-app my-app --template redux
andyarn create react-app my-app --template redux
considering that they have the same effect.
create-react-app uses yarn
explains it. – Centistere