mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
473eb1dd87
Summary: According to: https://jestjs.io/docs/configuration > It is recommended to define the configuration in a dedicated JavaScript, TypeScript or JSON file. The file will be discovered automatically, if it is named jest.config.js|ts|mjs|cjs|json. react-native projects have the jest config in package.json, this change aims to follow jest recommendations and have a dedicated file for jest configs. Originally suggested here: https://github.com/react-native-community/discussions-and-proposals/discussions/583 ## Changelog <!-- Help reviewers and the release process by writing your own changelog entry. Pick one each for the category and type tags: [ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message For more details, see: https://reactnative.dev/contributing/changelogs-in-pull-requests --> [GENERAL] [CHANGED] - Moved jest config from package.json to dedicated jest.config.js file Pull Request resolved: https://github.com/facebook/react-native/pull/35856 Test Plan: 1. cd template 2. yarn 3. yarn test The test should (still) pass Reviewed By: christophpurrer Differential Revision: D42544351 Pulled By: robhogan fbshipit-source-id: e27d1dad2b52d757777c40a77d0639f381557c88
34 lines
858 B
JSON
34 lines
858 B
JSON
{
|
|
"name": "HelloWorld",
|
|
"version": "0.0.1",
|
|
"private": true,
|
|
"scripts": {
|
|
"android": "react-native run-android",
|
|
"ios": "react-native run-ios",
|
|
"lint": "eslint .",
|
|
"start": "react-native start",
|
|
"test": "jest"
|
|
},
|
|
"dependencies": {
|
|
"react": "18.2.0",
|
|
"react-native": "1000.0.0"
|
|
},
|
|
"devDependencies": {
|
|
"@babel/core": "^7.20.0",
|
|
"@babel/preset-env": "^7.20.0",
|
|
"@babel/runtime": "^7.12.5",
|
|
"@react-native/eslint-config": "^0.72.1",
|
|
"@tsconfig/react-native": "^2.0.2",
|
|
"@types/jest": "^29.2.1",
|
|
"@types/react": "^18.0.24",
|
|
"@types/react-test-renderer": "^18.0.0",
|
|
"babel-jest": "^29.2.1",
|
|
"eslint": "^8.19.0",
|
|
"jest": "^29.2.1",
|
|
"metro-react-native-babel-preset": "0.73.5",
|
|
"prettier": "^2.4.1",
|
|
"react-test-renderer": "18.2.0",
|
|
"typescript": "4.8.4"
|
|
}
|
|
}
|