Files
react-native/packages/virtualized-lists/package.json
T
Andrew Coates dbf8e3f5ba Add @types/react as optional peerDependency on packages that use it (#43509)
Summary:
Now that RN is providing TS type information, many of those .d.ts files depend on types from react.  In modern packagemanagers (Ex: pnpm) types/react will not be available to RN since it does not declare it as a dependency.

I also noticed that the types for react-native-popup-menu-android appear to be pointing to the wrong location.

Add types/react as a peerDependency on the packages that have .d.ts files that import from React.
Add types/react to peerDependencyMeta with optional:true to prevent users not using TS from requiring types/react.

## Changelog:

[GENERAL] [ADDED] Added types/react as an optional peerDependency

Pull Request resolved: https://github.com/facebook/react-native/pull/43509

Reviewed By: cortinico

Differential Revision: D55225940

Pulled By: NickGerleman

fbshipit-source-id: 4cbab071928cb925baec45f55461559acc9a54e6
2024-03-25 12:23:16 -07:00

40 lines
933 B
JSON

{
"name": "@react-native/virtualized-lists",
"version": "0.75.0-main",
"description": "Virtualized lists for React Native.",
"license": "MIT",
"repository": {
"type": "git",
"url": "git+https://github.com/facebook/react-native.git",
"directory": "packages/virtualized-lists"
},
"homepage": "https://github.com/facebook/react-native/tree/HEAD/packages/virtualized-lists#readme",
"keywords": [
"lists",
"virtualized-lists",
"section-lists",
"react-native"
],
"bugs": "https://github.com/facebook/react-native/issues",
"engines": {
"node": ">=18"
},
"dependencies": {
"invariant": "^2.2.4",
"nullthrows": "^1.1.1"
},
"devDependencies": {
"react-test-renderer": "18.2.0"
},
"peerDependencies": {
"@types/react": "^18.2.6",
"react": "*",
"react-native": "*"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
}
}