@types/react 18.0.27 → 18.0.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
react/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for React (http://facebook.github.io/reac
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Wed, 18 Jan 2023 19:02:49 GMT
11
+ * Last updated: Fri, 24 Mar 2023 16:02:37 GMT
12
12
  * Dependencies: [@types/csstype](https://npmjs.com/package/@types/csstype), [@types/prop-types](https://npmjs.com/package/@types/prop-types), [@types/scheduler](https://npmjs.com/package/@types/scheduler)
13
13
  * Global values: `React`
14
14
 
react/experimental.d.ts CHANGED
@@ -104,5 +104,5 @@ declare module '.' {
104
104
  export const SuspenseList: ExoticComponent<SuspenseListProps>;
105
105
 
106
106
  // tslint:disable-next-line ban-types
107
- export function experimental_useEvent<T extends Function>(event: T): T;
107
+ export function experimental_useEffectEvent<T extends Function>(event: T): T;
108
108
  }
react/index.d.ts CHANGED
@@ -782,10 +782,10 @@ declare namespace React {
782
782
 
783
783
  /** Ensures that the props do not include ref at all */
784
784
  type PropsWithoutRef<P> =
785
- // Pick would not be sufficient for this. We'd like to avoid unnecessary mapping and need a distributive conditional to support unions.
785
+ // Omit would not be sufficient for this. We'd like to avoid unnecessary mapping and need a distributive conditional to support unions.
786
786
  // see: https://www.typescriptlang.org/docs/handbook/2/conditional-types.html#distributive-conditional-types
787
787
  // https://github.com/Microsoft/TypeScript/issues/28339
788
- P extends any ? ('ref' extends keyof P ? Pick<P, Exclude<keyof P, 'ref'>> : P) : P;
788
+ P extends any ? ('ref' extends keyof P ? Omit<P, 'ref'> : P) : P;
789
789
  /** Ensures that the props do not include string ref, which cannot be forwarded */
790
790
  type PropsWithRef<P> =
791
791
  // Just "P extends { ref?: infer R }" looks sufficient, but R will infer as {} if P is {}.
react/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/react",
3
- "version": "18.0.27",
3
+ "version": "18.0.29",
4
4
  "description": "TypeScript definitions for React",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react",
6
6
  "license": "MIT",
@@ -151,8 +151,8 @@
151
151
  "@types/scheduler": "*",
152
152
  "csstype": "^3.0.2"
153
153
  },
154
- "typesPublisherContentHash": "9fe92d5e956ab2c31da7ffe14998f63a047b60ad3535ea9d4c629616fe5f512d",
155
- "typeScriptVersion": "4.2",
154
+ "typesPublisherContentHash": "0b57cd9152ecf4ff05a80413cd6550a1943c8b944b1241e16cf8cc351aba79e0",
155
+ "typeScriptVersion": "4.3",
156
156
  "exports": {
157
157
  ".": {
158
158
  "types": {