Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions agents/example-apps.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

- 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 `/tmp` so repo-specific files can be restored selectively.
- Avoid image churn: preserve existing tracked image assets unless the task explicitly asks to update them or the new SDK requires an asset change.
- After copying a generated app into `examples/`, remove the generated `.git` directory and `node_modules`, then reinstall from inside the repo workspace.

## `examples/basic`
Expand All @@ -20,9 +21,10 @@
- `babel.config.js`
- `eslint.config.mjs`
- `README.md`
- existing tracked image assets in `assets/`
- `.expo-shared/assets.json` if it existed before
- Keep the fresh Expo entrypoint `index.ts`.
- Update `package.json` and `app.json` to match repo naming and scripts.
- Update `package.json` and `app.json` to match repo naming and scripts. Keep `app.json` pointing at the restored existing image assets unless changing them is intentional.

## `examples/cookbook`

Expand All @@ -39,9 +41,10 @@
- `.eslintignore`
- `README.md`
- custom assets not present in the scaffold, such as `assets/gradientRNBanner.png`
- existing tracked image assets in `assets/`
- `.expo-shared/assets.json` if it existed before
- Keep the fresh Expo Router entry setup.
- Reapply the cookbook-specific dependency set in `package.json` and `app.json`.
- Reapply the cookbook-specific dependency set in `package.json` and `app.json`. Keep `app.json` pointing at the restored existing image assets unless changing them is intentional.

## Validation after regeneration

Expand Down
2 changes: 1 addition & 1 deletion examples/basic/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
preset: 'react-native',
preset: '@react-native/jest-preset',
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json'],
transformIgnorePatterns: ['node_modules/(?!(jest-)?react-native|@react-native(-community)?)'],
setupFilesAfterEnv: ['./jest-setup.ts'],
Expand Down
41 changes: 21 additions & 20 deletions examples/basic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,37 +2,38 @@
"name": "rntl-example-basic",
"version": "1.0.0",
"main": "index.ts",
"scripts": {
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"web": "expo start --web",
"test": "jest",
"lint": "eslint .",
"typecheck": "tsc --noEmit",
"validate": "yarn expo install --check && yarn lint && yarn typecheck && yarn test --watchman=false"
},
"dependencies": {
"expo": "~54.0.33",
"expo-status-bar": "~3.0.9",
"react": "19.1.0",
"react-dom": "19.1.0",
"react-native": "0.81.5",
"react-native-safe-area-context": "^5.6.2",
"expo": "~56.0.8",
"expo-status-bar": "~56.0.4",
"react": "19.2.3",
"react-dom": "19.2.3",
"react-native": "0.85.3",
"react-native-safe-area-context": "~5.7.0",
"react-native-web": "^0.21.2"
},
"devDependencies": {
"@babel/core": "^7.29.0",
"@testing-library/react-native": "^14.0.0-beta.0",
"@react-native/jest-preset": "0.85.3",
"@testing-library/react-native": "14.0.0-rc.3",
"@types/jest": "^29.5.12",
"@types/react": "~19.1.10",
"@types/react": "~19.2.2",
"eslint": "^10.2.0",
"eslint-plugin-testing-library": "^7.16.2",
"jest": "~29.7.0",
"test-renderer": "0.16.0",
"typescript": "~5.9.2",
"test-renderer": "1.2.0",
"typescript": "~6.0.3",
"typescript-eslint": "^8.58.1"
},
"scripts": {
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"web": "expo start --web",
"test": "jest",
"lint": "eslint .",
"typecheck": "tsc --noEmit",
"validate": "yarn expo install --check && yarn lint && yarn typecheck && yarn test --watchman=false"
},
"private": true,
"packageManager": "yarn@4.11.0"
}
3 changes: 2 additions & 1 deletion examples/basic/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"extends": "expo/tsconfig.base",
"compilerOptions": {
"strict": true,
"allowJs": false
"allowJs": false,
"types": ["jest"]
}
}
Loading
Loading