https://github.com/danvc/create-react-app-multiple-entry-points
Example that shows up how to add multiple entry points on Create React App V3 (CRA)
https://github.com/danvc/create-react-app-multiple-entry-points
create-react-app multiple-entry multiple-pages react reactjs
Last synced: about 1 year ago
JSON representation
Example that shows up how to add multiple entry points on Create React App V3 (CRA)
- Host: GitHub
- URL: https://github.com/danvc/create-react-app-multiple-entry-points
- Owner: danvc
- Created: 2019-12-26T04:17:52.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-07-17T16:38:01.000Z (almost 6 years ago)
- Last Synced: 2025-03-24T15:01:44.463Z (about 1 year ago)
- Topics: create-react-app, multiple-entry, multiple-pages, react, reactjs
- Language: JavaScript
- Size: 592 KB
- Stars: 32
- Watchers: 1
- Forks: 10
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Create React App with multiple entry points
**Attention**: It's an `ejected` version of `create-react-app`, however, I'm going to push a PR for this missing feature. The non `ejected` version could be find here: https://github.com/DanZeuss/create-react-app
**There's a pending PR for this solution on https://github.com/facebook/create-react-app/pull/8249**
To add more entry points, follow the steps:
- Before cloning, please, slap ⭐️ now
- Add a new page in the `package.json` in the property `appPages`. There are 2 existing pages there: `index` and `login`;
- Create your new files for the new page. You should add a new `.html` file inside the `public` folder and also add your new `.js` file (related to your "new" app) inside your `src` folder.
- Run `yarn start` or `npm start`;
- Access your using the following url `/.hml`, for example: `http://localhost:3000/login.html`