From 8d0d5de250ed105730f74e2054c7174ef2e7f4c3 Mon Sep 17 00:00:00 2001 From: Andrew Coates <30809111+acoates-ms@users.noreply.github.com> Date: Mon, 18 May 2020 19:59:02 -0700 Subject: [PATCH] Reduce the changes in our custom metro config (#4939) * Reduce need for custom metro configs * Change files * Fix for integration tests --- ...ve-win32-2020-05-18-09-46-04-metrofix.json | 8 ++ ...-windows-2020-05-18-09-46-04-metrofix.json | 8 ++ packages/E2ETest/metro.config.js | 13 --- .../metro.config.js | 14 --- packages/playground/metro.config.js | 13 --- packages/react-native-win32/metro.config.js | 15 --- .../react-native-win32/react-native.config.js | 1 + .../templates/metro.config.js | 14 --- vnext/metro-react-native-platform.js | 77 --------------- vnext/metro.config.js | 39 +++++--- vnext/react-native.config.js | 1 + yarn.lock | 98 ++++++++++++------- 12 files changed, 110 insertions(+), 191 deletions(-) create mode 100644 change/@office-iss-react-native-win32-2020-05-18-09-46-04-metrofix.json create mode 100644 change/react-native-windows-2020-05-18-09-46-04-metrofix.json delete mode 100644 vnext/metro-react-native-platform.js diff --git a/change/@office-iss-react-native-win32-2020-05-18-09-46-04-metrofix.json b/change/@office-iss-react-native-win32-2020-05-18-09-46-04-metrofix.json new file mode 100644 index 00000000000..f034cee4376 --- /dev/null +++ b/change/@office-iss-react-native-win32-2020-05-18-09-46-04-metrofix.json @@ -0,0 +1,8 @@ +{ + "type": "prerelease", + "comment": "Reduce need for custom metro configs", + "packageName": "@office-iss/react-native-win32", + "email": "acoates@microsoft.com", + "dependentChangeType": "patch", + "date": "2020-05-18T16:46:03.284Z" +} diff --git a/change/react-native-windows-2020-05-18-09-46-04-metrofix.json b/change/react-native-windows-2020-05-18-09-46-04-metrofix.json new file mode 100644 index 00000000000..c97e533475f --- /dev/null +++ b/change/react-native-windows-2020-05-18-09-46-04-metrofix.json @@ -0,0 +1,8 @@ +{ + "type": "prerelease", + "comment": "Reduce need for custom metro configs", + "packageName": "react-native-windows", + "email": "acoates@microsoft.com", + "dependentChangeType": "patch", + "date": "2020-05-18T16:46:04.876Z" +} diff --git a/packages/E2ETest/metro.config.js b/packages/E2ETest/metro.config.js index dd5772a7d4b..fed6bb3d849 100644 --- a/packages/E2ETest/metro.config.js +++ b/packages/E2ETest/metro.config.js @@ -6,10 +6,6 @@ */ const path = require('path'); const blacklist = require('metro-config/src/defaults/blacklist'); -const { - getModulesRunBeforeMainModule, - reactNativePlatformResolver, -} = require('react-native-windows/metro-react-native-platform'); const rnwPath = path.resolve(__dirname, '../../vnext'); @@ -23,9 +19,6 @@ module.exports = { ], resolver: { - resolveRequest: reactNativePlatformResolver({ - windows: 'react-native-windows', - }), extraNodeModules: { // Redirect metro to rnwPath instead of node_modules/react-native-windows, since metro doesn't like symlinks 'react-native-windows': rnwPath, @@ -38,13 +31,7 @@ module.exports = { ), ]), }, - serializer: { - getModulesRunBeforeMainModule, - }, transformer: { - // The cli defaults this to a full path to react-native, which bypasses the reactNativePlatformResolver above - // Hopefully we can fix the default in the future - assetRegistryPath: 'react-native/Libraries/Image/AssetRegistry', getTransformOptions: async () => ({ transform: { experimentalImportSupport: false, diff --git a/packages/microsoft-reactnative-sampleapps/metro.config.js b/packages/microsoft-reactnative-sampleapps/metro.config.js index 051c80f4a7f..9b560caf9f6 100644 --- a/packages/microsoft-reactnative-sampleapps/metro.config.js +++ b/packages/microsoft-reactnative-sampleapps/metro.config.js @@ -6,11 +6,6 @@ */ const path = require('path'); const blacklist = require('metro-config/src/defaults/blacklist'); -const { - getModulesRunBeforeMainModule, - reactNativePlatformResolver, -} = require('react-native-windows/metro-react-native-platform'); - const rnwPath = path.resolve(__dirname, '../../vnext'); module.exports = { @@ -23,9 +18,6 @@ module.exports = { ], resolver: { - resolveRequest: reactNativePlatformResolver({ - windows: 'react-native-windows', - }), extraNodeModules: { // Redirect metro to rnwPath instead of node_modules/react-native-windows, since metro doesn't like symlinks 'react-native-windows': rnwPath, @@ -40,13 +32,7 @@ module.exports = { ), ]), }, - serializer: { - getModulesRunBeforeMainModule, - }, transformer: { - // The cli defaults this to a full path to react-native, which bypasses the reactNativePlatformResolver above - // Hopefully we can fix the default in the future - assetRegistryPath: 'react-native/Libraries/Image/AssetRegistry', getTransformOptions: async () => ({ transform: { experimentalImportSupport: false, diff --git a/packages/playground/metro.config.js b/packages/playground/metro.config.js index 9d3e6b90a00..928a5cb1dd5 100644 --- a/packages/playground/metro.config.js +++ b/packages/playground/metro.config.js @@ -7,10 +7,6 @@ const fs = require('fs'); const path = require('path'); const blacklist = require('metro-config/src/defaults/blacklist'); -const { - getModulesRunBeforeMainModule, - reactNativePlatformResolver, -} = require('react-native-windows/metro-react-native-platform'); const rnwPath = fs.realpathSync( path.resolve(require.resolve('react-native-windows/package.json'), '..'), @@ -26,9 +22,6 @@ module.exports = { ], resolver: { - resolveRequest: reactNativePlatformResolver({ - windows: 'react-native-windows', - }), extraNodeModules: { // Redirect react-native-windows to avoid symlink (metro doesn't like symlinks) 'react-native-windows': rnwPath, @@ -40,13 +33,7 @@ module.exports = { ), ]), }, - serializer: { - getModulesRunBeforeMainModule, - }, transformer: { - // The cli defaults this to a full path to react-native, which bypasses the reactNativePlatformResolver above - // Hopefully we can fix the default in the future - assetRegistryPath: 'react-native/Libraries/Image/AssetRegistry', getTransformOptions: async () => ({ transform: { experimentalImportSupport: false, diff --git a/packages/react-native-win32/metro.config.js b/packages/react-native-win32/metro.config.js index 084652f0ad0..58f3308a128 100644 --- a/packages/react-native-win32/metro.config.js +++ b/packages/react-native-win32/metro.config.js @@ -3,10 +3,6 @@ */ const fs = require('fs'); const path = require('path'); -const { - getModulesRunBeforeMainModule, - reactNativePlatformResolver, -} = require('./metro-react-native-platform'); module.exports = { // WatchFolders is only needed due to the yarn workspace layout of node_modules, we need to watch the symlinked locations separately @@ -15,18 +11,7 @@ module.exports = { path.resolve(__dirname, '../../node_modules'), ], - resolver: { - resolveRequest: reactNativePlatformResolver({ - win32: '@office-iss/react-native-win32', - }), - }, - serializer: { - getModulesRunBeforeMainModule, - }, transformer: { - // The cli defaults this to a full path to react-native, which bypasses the reactNativePlatformResolver above - // Hopefully we can fix the default in the future - assetRegistryPath: 'react-native/Libraries/Image/AssetRegistry', getTransformOptions: async () => ({ transform: { experimentalImportSupport: false, diff --git a/packages/react-native-win32/react-native.config.js b/packages/react-native-win32/react-native.config.js index 6c2312774ef..dacf5861050 100644 --- a/packages/react-native-win32/react-native.config.js +++ b/packages/react-native-win32/react-native.config.js @@ -6,6 +6,7 @@ module.exports = { linkConfig: () => null, projectConfig: (projectRoot, projectParams) => null, dependencyConfig: (projectRoot, dependencyParams) => null, + npmPackageName: '@office-iss/react-native-win32', }, }, }; diff --git a/vnext/local-cli/generator-windows/templates/metro.config.js b/vnext/local-cli/generator-windows/templates/metro.config.js index a1e6b552e99..9a167301bf0 100644 --- a/vnext/local-cli/generator-windows/templates/metro.config.js +++ b/vnext/local-cli/generator-windows/templates/metro.config.js @@ -7,16 +7,8 @@ const path = require('path'); const blacklist = require('metro-config/src/defaults/blacklist'); -const { - getModulesRunBeforeMainModule, - reactNativePlatformResolver, -} = require('react-native-windows/metro-react-native-platform'); - module.exports = { resolver: { - resolveRequest: reactNativePlatformResolver({ - windows: 'react-native-windows', - }), blacklistRE: blacklist([ // This stops "react-native run-windows" from causing the metro server to crash if its already running new RegExp( @@ -30,13 +22,7 @@ module.exports = { ), ]), }, - serializer: { - getModulesRunBeforeMainModule, - }, transformer: { - // The cli defaults this to a full path to react-native, which bypasses the reactNativePlatformResolver above - // Hopefully we can fix the default in the future - assetRegistryPath: 'react-native/Libraries/Image/AssetRegistry', getTransformOptions: async () => ({ transform: { experimentalImportSupport: false, diff --git a/vnext/metro-react-native-platform.js b/vnext/metro-react-native-platform.js deleted file mode 100644 index e9acdf525a7..00000000000 --- a/vnext/metro-react-native-platform.js +++ /dev/null @@ -1,77 +0,0 @@ -/** - * @format - */ -const {resolve} = require('metro-resolver'); - -/** - * platformImplementations is a map of platform to npm package that implements that platform - * - * Ex: - * { - * windows: 'react-native-windows' - * macos: 'react-native-macos' - * } - */ -function reactNativePlatformResolver(platformImplementations) { - return (context, _realModuleName, platform, moduleName) => { - let backupResolveRequest = context.resolveRequest; - delete context.resolveRequest; - - try { - let modifiedModuleName = moduleName; - if (platformImplementations[platform]) { - if (moduleName === 'react-native') { - modifiedModuleName = platformImplementations[platform]; - } else if (moduleName.startsWith('react-native/')) { - modifiedModuleName = `${ - platformImplementations[platform] - }/${modifiedModuleName.slice('react-native/'.length)}`; - } - } - let result = resolve(context, modifiedModuleName, platform); - context.resolveRequest = backupResolveRequest; - return result; - } catch (e) { - context.resolveRequest = backupResolveRequest; - throw e; - } - }; -} - -/** - * The CLI will get a more complete implementation of this in https://github.com/react-native-community/cli/pull/1115 - * but until then, use a solution that supports having react-native-windows and/or react-native-macos - */ -const getModulesRunBeforeMainModule = () => { - const options = { - paths: [process.cwd()], - }; - const modules = [ - require.resolve('react-native/Libraries/Core/InitializeCore', options), - ]; - - try { - modules.push( - require.resolve( - 'react-native-windows/Libraries/Core/InitializeCore', - options, - ), - ); - } catch {} - - try { - modules.push( - require.resolve( - 'react-native-macos/Libraries/Core/InitializeCore', - options, - ), - ); - } catch {} - - return modules; -}; - -module.exports = { - getModulesRunBeforeMainModule, - reactNativePlatformResolver, -}; diff --git a/vnext/metro.config.js b/vnext/metro.config.js index 3082ecc5edc..9ec73254b19 100644 --- a/vnext/metro.config.js +++ b/vnext/metro.config.js @@ -3,13 +3,34 @@ */ const fs = require('fs'); const path = require('path'); +const rnwPath = __dirname; +const {resolve} = require('metro-resolver'); -const { - getModulesRunBeforeMainModule, - reactNativePlatformResolver, -} = require('react-native-windows/metro-react-native-platform'); +function reactNativePlatformResolver(platformImplementations) { + return (context, _realModuleName, platform, moduleName) => { + let backupResolveRequest = context.resolveRequest; + delete context.resolveRequest; -const rnwPath = __dirname; + try { + let modifiedModuleName = moduleName; + if (platformImplementations[platform]) { + if (moduleName === 'react-native') { + modifiedModuleName = platformImplementations[platform]; + } else if (moduleName.startsWith('react-native/')) { + modifiedModuleName = `${ + platformImplementations[platform] + }/${modifiedModuleName.slice('react-native/'.length)}`; + } + } + let result = resolve(context, modifiedModuleName, platform); + return result; + } catch (e) { + throw e; + } finally { + context.resolveRequest = backupResolveRequest; + } + }; +} module.exports = { // WatchFolders is only needed due to the yarn workspace layout of node_modules, we need to watch the symlinked locations separately @@ -19,6 +40,7 @@ module.exports = { ], resolver: { + // We need a custom resolveRequest right now since our integration tests use a "windesktop" platform thats specific to integration tests. resolveRequest: reactNativePlatformResolver({ windesktop: 'react-native-windows', windows: 'react-native-windows', @@ -29,14 +51,7 @@ module.exports = { }, }, - serializer: { - getModulesRunBeforeMainModule, - }, - transformer: { - // The cli defaults this to a full path to react-native, which bypasses the reactNativePlatformResolver above - // Hopefully we can fix the default in the future - assetRegistryPath: 'react-native/Libraries/Image/AssetRegistry', getTransformOptions: async () => ({ transform: { experimentalImportSupport: false, diff --git a/vnext/react-native.config.js b/vnext/react-native.config.js index d427f0050f4..9a81411678b 100644 --- a/vnext/react-native.config.js +++ b/vnext/react-native.config.js @@ -12,6 +12,7 @@ module.exports = { linkConfig: () => null, projectConfig: projectConfig.projectConfigWindows, dependencyConfig: dependencyConfig.dependencyConfigWindows, + npmPackageName: 'react-native-windows', }, }, }; diff --git a/yarn.lock b/yarn.lock index 85528cfb782..6c475019386 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1228,6 +1228,16 @@ "@types/yargs" "^15.0.0" chalk "^3.0.0" +"@jest/types@^25.5.0": + version "25.5.0" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-25.5.0.tgz#4d6a4793f7b9599fc3680877b856a97dbccf2a9d" + integrity sha512-OXD0RgQ86Tu3MazKo8bnrkDRaDXXMGUqd+kTtLtK1Zb7CRzQcaSRPPPV37SvYTdevXEBVxe0HXylEjs8ibkmCw== + dependencies: + "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^1.1.1" + "@types/yargs" "^15.0.0" + chalk "^3.0.0" + "@jimp/bmp@^0.5.4": version "0.5.4" resolved "https://registry.yarnpkg.com/@jimp/bmp/-/bmp-0.5.4.tgz#b7b375aa774f26154912569864d5466e71333ef1" @@ -2560,19 +2570,19 @@ command-line-args "^5.0.2" command-line-usage "^5.0.5" -"@react-native-community/cli-debugger-ui@^4.2.1": - version "4.2.1" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-debugger-ui/-/cli-debugger-ui-4.2.1.tgz#da22aa1cf8d04fe1aa2759873916473e81c4450b" - integrity sha512-/lvb39Pgo7bM9rsJ2aMomM7jCGWRpnO2iLECJz1ehC49Fblbosh3qtTsg9WWEVTHoY/34GhaQ7EzQxdSfH8pwg== +"@react-native-community/cli-debugger-ui@^4.9.0": + version "4.9.0" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-debugger-ui/-/cli-debugger-ui-4.9.0.tgz#4177764ba69243c97aa26829d59d9501acb2bd71" + integrity sha512-fBFGamHm4VUrDqkBGnsrwQL8OC6Om7K6EBQb4xj0nWekpXt1HSa3ScylYHTTWwYcpRf9htGMRGiv4dQDY/odAw== dependencies: serve-static "^1.13.1" "@react-native-community/cli-platform-android@^4.5.1": - version "4.6.0" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-platform-android/-/cli-platform-android-4.6.0.tgz#74ad0b2e29ab2a3ced58e07d2c2a99b9577046e2" - integrity sha512-wLDqml335sKI/FXG72oFn5DXhNbT/k2+t0VHqUUdT2yhbtSQ2kvYaZh/30rlUPYkBiwuxjQW9kGwlQtKs/mQsg== + version "4.9.0" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-platform-android/-/cli-platform-android-4.9.0.tgz#12ba32875afca81202e1dbf0005f022fa9158352" + integrity sha512-Tw2rQ84zXl5BGZT3rWmDXXUtkmHr73qa/qaP2WMemHTM28boXBdzkkVCnJMdCLZnCphOcpikYsBQALgqFKWOeQ== dependencies: - "@react-native-community/cli-tools" "^4.6.0" + "@react-native-community/cli-tools" "^4.9.0" chalk "^3.0.0" execa "^1.0.0" fs-extra "^8.1.0" @@ -2584,11 +2594,11 @@ xmldoc "^1.1.2" "@react-native-community/cli-platform-ios@^4.5.0": - version "4.6.0" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-platform-ios/-/cli-platform-ios-4.6.0.tgz#c4b5fcdd060b356ca5cadb76b41ed57f1ec7ef29" - integrity sha512-4wL0usFDzs43wZDTxtZDGxoGWlEH/ggroQwFIGwtiAJOaWzING4KJ3b0KJQMnTDjEzLUdXKBvvhBrX2VRnQv2A== + version "4.9.0" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-platform-ios/-/cli-platform-ios-4.9.0.tgz#211ca9cd3976fbbb41406c0a846e445cc04c773c" + integrity sha512-8BWe3XM1vKS2/BXXDL5gbD/5rA/u34Irs0Ublrx1JSGqv83g7T9V2DlBMR5xYRbhBWnWnGXVhsN1ckxlkXh8PA== dependencies: - "@react-native-community/cli-tools" "^4.6.0" + "@react-native-community/cli-tools" "^4.9.0" chalk "^3.0.0" glob "^7.1.3" js-yaml "^3.13.1" @@ -2596,39 +2606,53 @@ plist "^3.0.1" xcode "^2.0.0" -"@react-native-community/cli-tools@^4.6.0": - version "4.6.0" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-tools/-/cli-tools-4.6.0.tgz#9c6607842a3dd98897c236602192eba8886d48e6" - integrity sha512-x2vD+pJKTPipjyRQrxqBT7uQksbM0ByWIm9853YRUjKs1/i+LfhlukDVFYH6fImUW5ySKzxa0LBih0rlckSTBQ== +"@react-native-community/cli-server-api@^4.9.0": + version "4.9.0" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-server-api/-/cli-server-api-4.9.0.tgz#503f50331c6e2cc8c5fcf6b693170e3a3a669d1a" + integrity sha512-lKBIXJjFLyu4+6Vhhj/QzD41aQGkVi8xWLqTYCgi26d61kjLuuZs0Xer02DPJK3+YADKExVdWrJzVHfJ7zYlTA== + dependencies: + "@react-native-community/cli-debugger-ui" "^4.9.0" + "@react-native-community/cli-tools" "^4.9.0" + compression "^1.7.1" + connect "^3.6.5" + errorhandler "^1.5.0" + pretty-format "^25.1.0" + serve-static "^1.13.1" + ws "^1.1.0" + +"@react-native-community/cli-tools@^4.9.0": + version "4.9.0" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-tools/-/cli-tools-4.9.0.tgz#d8fd0326cc2fcaeb8c920baf24b68b63c8164fa2" + integrity sha512-vCeYkJ3n/EIaW3lAfznzojMffGxYhCUzwZzwBuC3+O+gYxkymdpletqNYLLEa04DzJr174mxgbgBw8g5IP91yA== dependencies: chalk "^3.0.0" lodash "^4.17.15" mime "^2.4.1" node-fetch "^2.6.0" + open "^6.2.0" + shell-quote "1.6.1" -"@react-native-community/cli-types@^4.6.0": - version "4.6.0" - resolved "https://registry.yarnpkg.com/@react-native-community/cli-types/-/cli-types-4.6.0.tgz#7a1228cccd0bde94875098b8e23f761d46f750fd" - integrity sha512-juEA0j9gkHyKqOvwVQ2+BdyJW4ZOYo9bTR0a7CCVnY5UWiGTBBixRyShovrczWF6cKXmE+lscO5nJLh63XqFFQ== +"@react-native-community/cli-types@^4.9.0": + version "4.9.0" + resolved "https://registry.yarnpkg.com/@react-native-community/cli-types/-/cli-types-4.9.0.tgz#4c80b5f3789f2d3ee744e4fbb01ce839d8399ac3" + integrity sha512-Sjun3LHuuuA6G9NIiyiqolNA7NP0CBGhbQA7twslJi3VaE1kj7OdBRCzpPtIYwK8eFWv3CEc/Qh+CoAw83Jp8A== "@react-native-community/cli@^4.5.1": - version "4.6.0" - resolved "https://registry.yarnpkg.com/@react-native-community/cli/-/cli-4.6.0.tgz#ded55ebba5d83cfd5ace2565ac7e566f058c3a04" - integrity sha512-rCY5CwBYYr1GJDXy8A8kHkJGZrCFIjEHCW6oRAPtB/8Th7If9qKIR7OJj2V7G3ihOwW6yPhR/FiOBckdG9KD+g== + version "4.9.0" + resolved "https://registry.yarnpkg.com/@react-native-community/cli/-/cli-4.9.0.tgz#3525d831087e084861ca484569ebfb9b1a63faac" + integrity sha512-Aai8Tan2nJWbtJIzEMe/BrbbGFAAdusgXZ5/NB1k5oFUS6iXvW18+59ssC8FR2qGPbOLBg87oDn4Pca2u4CTlQ== dependencies: "@hapi/joi" "^15.0.3" - "@react-native-community/cli-debugger-ui" "^4.2.1" - "@react-native-community/cli-tools" "^4.6.0" - "@react-native-community/cli-types" "^4.6.0" + "@react-native-community/cli-debugger-ui" "^4.9.0" + "@react-native-community/cli-server-api" "^4.9.0" + "@react-native-community/cli-tools" "^4.9.0" + "@react-native-community/cli-types" "^4.9.0" chalk "^3.0.0" command-exists "^1.2.8" commander "^2.19.0" - compression "^1.7.1" - connect "^3.6.5" cosmiconfig "^5.1.0" deepmerge "^3.2.0" envinfo "^7.1.0" - errorhandler "^1.5.0" execa "^1.0.0" find-up "^4.1.0" fs-extra "^8.1.0" @@ -2641,19 +2665,17 @@ metro-config "^0.58.0" metro-core "^0.58.0" metro-react-native-babel-transformer "^0.58.0" + metro-resolver "^0.58.0" minimist "^1.2.0" mkdirp "^0.5.1" node-stream-zip "^1.9.1" - open "^6.2.0" ora "^3.4.0" pretty-format "^25.2.0" semver "^6.3.0" serve-static "^1.13.1" - shell-quote "1.6.1" strip-ansi "^5.2.0" sudo-prompt "^9.0.0" wcwidth "^1.0.1" - ws "^1.1.0" "@react-native-community/eslint-config@^1.0.0": version "1.1.0" @@ -9794,7 +9816,7 @@ metro-react-native-babel-transformer@0.58.0, metro-react-native-babel-transforme metro-react-native-babel-preset "0.58.0" metro-source-map "0.58.0" -metro-resolver@0.58.0: +metro-resolver@0.58.0, metro-resolver@^0.58.0: version "0.58.0" resolved "https://registry.yarnpkg.com/metro-resolver/-/metro-resolver-0.58.0.tgz#4d03edc52e2e25d45f16688adf3b3f268ea60df9" integrity sha512-XFbAKvCHN2iWqKeiRARzEXn69eTDdJVJC7lu16S4dPQJ+Dy82dZBr5Es12iN+NmbJuFgrAuIHbpWrdnA9tOf6Q== @@ -11264,6 +11286,16 @@ pretty-format@^24.7.0, pretty-format@^24.9.0: ansi-styles "^3.2.0" react-is "^16.8.4" +pretty-format@^25.1.0: + version "25.5.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-25.5.0.tgz#7873c1d774f682c34b8d48b6743a2bf2ac55791a" + integrity sha512-kbo/kq2LQ/A/is0PQwsEHM7Ca6//bGPPvU6UnsdDRSKTWxT/ru/xb88v4BJf6a69H+uTytOEsTusT9ksd/1iWQ== + dependencies: + "@jest/types" "^25.5.0" + ansi-regex "^5.0.0" + ansi-styles "^4.0.0" + react-is "^16.12.0" + pretty-format@^25.2.0: version "25.2.6" resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-25.2.6.tgz#542a1c418d019bbf1cca2e3620443bc1323cb8d7"