Create react apps with parcel instead of webpack cos why not
create react apps with parcel instead of webpack cos why not
Preconfigured Features that come with your Parcel setup:
App.jsto show off the babel preset features (click on the React logo!)
npm, environment variables all the same)
npx create-react-app-parcel my-app
or install it:
npm i -g create-react-app-parcel
cd my-app yarn start
and presto! (try clicking the react icon)
You will have a very simple folder structure, same as
my-app ├── README.md ├── node_modules ├── package.json ├── .gitignore ├── public │ └── favicon.ico │ └── index.html │ └── manifest.json └── src └── App.css └── App.js └── App.test.js └── index.css └── index.js └── logo.svg └── registerServiceWorker.js
No configuration or complicated folder structures, just the files you need to build your app.
Runs the app in development mode.
Open http://localhost:1234 to view it in the browser.
The page will automatically reload if you make changes to the code.
You will see the build errors and lint warnings in the console.
⚠️ warning: this functionality is untested for now
npm run buildor
Builds the app for production to the
The build is minified and the filenames include the hashes.
Your app is ready to be deployed.
ejects you out of this shiznit like so
Check out the slide deck at https://twitter.com/swyx/status/999474452571283456 and https://www.beautiful.ai/player/-LD4eaMxlqSlCy6biPmZ/Creating-Create-React-App/1?ref=github-crap. Also check out the talk video here!
We'd love to have your helping hand on
create-react-app-parcel! Ping me on twitter @assuncaocharles to discuss or file an issue, this is super new
We are grateful to the authors of existing related projects for their ideas and collaboration:
Create React App Parcel is open source software licensed as MIT.
of course it's the 💩
There's this dinky little me-too project called create-react-app, send them some love, who knows they could be big someday.
Also for Typescript users a custom script exists: https://github.com/sw-yx/create-react-app-parcel-typescript
crap my-ts-app --scripts-version=create-react-app-parcel-typescript