- Regenerate Expo example apps in a temporary directory, then copy the fresh scaffold into place.
- Before replacing an example app, move the current app directory to
/tmpso repo-specific files can be restored selectively. - After copying a generated app into
examples/, remove the generated.gitdirectory andnode_modules, then reinstall from inside the repo workspace.
- Generate from the Expo blank TypeScript template:
yarn create expo-app /tmp/rntl-basic-fresh --template blank-typescript --yes
- Restore these repo-specific files on top of the fresh scaffold:
App.tsxcomponents/__tests__/theme.tsjest.config.jsjest-setup.tsbabel.config.jseslint.config.mjsREADME.md.expo-shared/assets.jsonif it existed before
- Keep the fresh Expo entrypoint
index.ts. - Update
package.jsonandapp.jsonto match repo naming and scripts.
- Generate from a router-enabled Expo scaffold:
yarn create expo-app /tmp/rntl-cookbook-fresh --example with-router --yes
- Restore these repo-specific files on top of the fresh scaffold:
app/- tutorial test directories such as
basics-tutorial/andbasics-tutorial-react-strict-dom/ theme.tsjest.config.jsjest-setup.tsbabel.config.js.eslintrc.eslintignoreREADME.md- custom assets not present in the scaffold, such as
assets/gradientRNBanner.png .expo-shared/assets.jsonif it existed before
- Keep the fresh Expo Router entry setup.
- Reapply the cookbook-specific dependency set in
package.jsonandapp.json.
- Run these commands from inside the regenerated app directory:
yarn expo install --checkyarn lintyarn typecheckyarn test --watchman=false
- If the fresh scaffold causes dependency-resolution churn, restore the previous
yarn.lockfirst and then runyarn installinstead of re-resolving the full tree.