npx create-react-app@next --scripts-version=@next --template=cra-template@next my-js-app
npx create-react-app@next --scripts-version=@next --template=typescript@next my-ts-app
To update an existing app you can change the react-scripts
version in package.json
to next
and then run yarn
or npm install
You can see a list of all the changes in the 4.0 release here
Tried out
4.0.0-next.98
today (coming from3.4.3
) in a medium-sized typescript monorepo. Our app builds and runs just fine.Unfortunately some of our Jest tests broke. It looks like ts-jest is no longer getting used. Previously (with CRA3) we were able to specify a transform in the
jest
section ofpackage.json
like this:This allowed us to use TypeScript features not supported by Babel (like
emitDecoratorMetadata
for TypeORM).Looking at the v3.4.1...master diff, I'm not sure what broke it. Perhaps something about Jest 26?