react-boilerplate-cra-template
react-boilerplate-cra-template copied to clipboard
Ejecting from CRA
We are going to use this repo for production apps in my organization. We need to able to customize webpack configurations to setup a Micro Front End Architecture using this boilerplate. We are also planning to use swc instead of babel and typescript for transpiling and compiling respectively. Typescript will be used throughout the project with React 18.
A hard requirement is to be able to do SSR.
We also should be able to update the packages across our app periodically (as and when necessary). I guess if we don't eject, we will be dependent on CRA for upgrades to packages that have been abstracted away but we will be able to update other packages.
Is it advisable to run npm run eject
and get control of everything from CRA OR is it possible for us to do the above things without ejecting ?
@rishu605 I started from this template to build a production ready boilerplate.
As it's a CRA template it's still based on react-scripts
until you eject (mostly for the Webpack part).
As CRA is unmaintained now I recommend you to eject to get control on every config layers.
I also recommend you to split the package.json
on order to split different configs (e.g babel, prettier....)
If at some point you need to update the backbone of your app, you can check how the updates were made by maintainers of CRA.
Good luck 👋