mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Summary: This adds `react-native/metro-config` to the monorepo build tool and emits the missing typescript declarations. Right now, we do have typescript declarations on `metro-config`, but not `react-native/metro-config`. Which makes everything a bit harder extend from "[the default React Native metro config](https://github.com/facebook/react-native/pull/36502)" in Expo. > Note, I also added the same `exports` block from `react-native/dev-middleware` for conformity. One open question here is, why aren't we exporting _all_ helper functions from `metro-config`? To me, its a bit weird that we need both `metro-config` _and_ `react-native/metro-config` as `loadConfig` isn't exported. ## Changelog: [INTERNAL] [FIXED] - Emit typescript declaration files for `react-native/metro-config` Pull Request resolved: https://github.com/facebook/react-native/pull/41836 Test Plan: Run the build tool, and check if the typescript declarations are emitted for `react-native/metro-config`. ``` yarn build metro-config ``` Reviewed By: hoxyq Differential Revision: D51943453 Pulled By: huntie fbshipit-source-id: cfaffe5660053fc9a9fcbe3dacf7f6ccc2bde01b
35 lines
851 B
JSON
35 lines
851 B
JSON
{
|
|
"name": "@react-native/metro-config",
|
|
"version": "0.74.0",
|
|
"description": "Metro configuration for React Native.",
|
|
"license": "MIT",
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "https://github.com/facebook/react-native.git",
|
|
"directory": "packages/metro-config"
|
|
},
|
|
"homepage": "https://github.com/facebook/react-native/tree/HEAD/packages/metro-config#readme",
|
|
"keywords": [
|
|
"metro",
|
|
"config",
|
|
"react-native"
|
|
],
|
|
"bugs": "https://github.com/facebook/react-native/issues",
|
|
"engines": {
|
|
"node": ">=18"
|
|
},
|
|
"exports": {
|
|
".": "./src/index.js",
|
|
"./package.json": "./package.json"
|
|
},
|
|
"files": [
|
|
"dist"
|
|
],
|
|
"dependencies": {
|
|
"@react-native/js-polyfills": "0.74.0",
|
|
"@react-native/metro-babel-transformer": "0.74.0",
|
|
"metro-config": "^0.80.3",
|
|
"metro-runtime": "^0.80.3"
|
|
}
|
|
}
|