@types/react 19.2.2 → 19.2.4
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 +1 -1
- react/experimental.d.ts +8 -5
- react/package.json +2 -2
- react/ts5.0/experimental.d.ts +8 -5
react/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for react (https://react.dev/).
|
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Wed, 12 Nov 2025 16:02:25 GMT
|
|
12
12
|
* Dependencies: [csstype](https://npmjs.com/package/csstype)
|
|
13
13
|
|
|
14
14
|
# Credits
|
react/experimental.d.ts
CHANGED
|
@@ -43,12 +43,13 @@ type VoidOrUndefinedOnly = void | { [UNDEFINED_VOID_ONLY]: never };
|
|
|
43
43
|
|
|
44
44
|
declare module "." {
|
|
45
45
|
export interface SuspenseProps {
|
|
46
|
+
// @enableCPUSuspense
|
|
46
47
|
/**
|
|
47
48
|
* The presence of this prop indicates that the content is computationally expensive to render.
|
|
48
49
|
* In other words, the tree is CPU bound and not I/O bound (e.g. due to fetching data).
|
|
49
50
|
* @see {@link https://github.com/facebook/react/pull/19936}
|
|
50
51
|
*/
|
|
51
|
-
|
|
52
|
+
defer?: boolean | undefined;
|
|
52
53
|
}
|
|
53
54
|
|
|
54
55
|
export type SuspenseListRevealOrder = "forwards" | "backwards" | "together" | "independent";
|
|
@@ -68,17 +69,19 @@ declare module "." {
|
|
|
68
69
|
children: Iterable<ReactElement> | AsyncIterable<ReactElement>;
|
|
69
70
|
/**
|
|
70
71
|
* Defines the order in which the `SuspenseList` children should be revealed.
|
|
72
|
+
* @default "forwards"
|
|
71
73
|
*/
|
|
72
|
-
revealOrder
|
|
74
|
+
revealOrder?: "forwards" | "backwards" | "unstable_legacy-backwards" | undefined;
|
|
73
75
|
/**
|
|
74
76
|
* Dictates how unloaded items in a SuspenseList is shown.
|
|
75
77
|
*
|
|
76
|
-
* - By default, `SuspenseList` will show all fallbacks in the list.
|
|
77
78
|
* - `collapsed` shows only the next fallback in the list.
|
|
78
79
|
* - `hidden` doesn't show any unloaded items.
|
|
79
80
|
* - `visible` shows all fallbacks in the list.
|
|
81
|
+
*
|
|
82
|
+
* @default "hidden"
|
|
80
83
|
*/
|
|
81
|
-
tail
|
|
84
|
+
tail?: SuspenseListTailMode | undefined;
|
|
82
85
|
}
|
|
83
86
|
|
|
84
87
|
interface NonDirectionalSuspenseListProps extends SuspenseListCommonProps {
|
|
@@ -86,7 +89,7 @@ declare module "." {
|
|
|
86
89
|
/**
|
|
87
90
|
* Defines the order in which the `SuspenseList` children should be revealed.
|
|
88
91
|
*/
|
|
89
|
-
revealOrder: Exclude<SuspenseListRevealOrder, DirectionalSuspenseListProps["revealOrder"]
|
|
92
|
+
revealOrder: Exclude<SuspenseListRevealOrder, DirectionalSuspenseListProps["revealOrder"]>;
|
|
90
93
|
/**
|
|
91
94
|
* The tail property is invalid when not using the `forwards` or `backwards` reveal orders.
|
|
92
95
|
*/
|
react/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/react",
|
|
3
|
-
"version": "19.2.
|
|
3
|
+
"version": "19.2.4",
|
|
4
4
|
"description": "TypeScript definitions for react",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react",
|
|
6
6
|
"license": "MIT",
|
|
@@ -205,6 +205,6 @@
|
|
|
205
205
|
"csstype": "^3.0.2"
|
|
206
206
|
},
|
|
207
207
|
"peerDependencies": {},
|
|
208
|
-
"typesPublisherContentHash": "
|
|
208
|
+
"typesPublisherContentHash": "beb6cb0d4cea447e7c02796fed7809694045a85f63ccee65d1eafe9a3ce86b6f",
|
|
209
209
|
"typeScriptVersion": "5.2"
|
|
210
210
|
}
|
react/ts5.0/experimental.d.ts
CHANGED
|
@@ -43,12 +43,13 @@ type VoidOrUndefinedOnly = void | { [UNDEFINED_VOID_ONLY]: never };
|
|
|
43
43
|
|
|
44
44
|
declare module "." {
|
|
45
45
|
export interface SuspenseProps {
|
|
46
|
+
// @enableCPUSuspense
|
|
46
47
|
/**
|
|
47
48
|
* The presence of this prop indicates that the content is computationally expensive to render.
|
|
48
49
|
* In other words, the tree is CPU bound and not I/O bound (e.g. due to fetching data).
|
|
49
50
|
* @see {@link https://github.com/facebook/react/pull/19936}
|
|
50
51
|
*/
|
|
51
|
-
|
|
52
|
+
defer?: boolean | undefined;
|
|
52
53
|
}
|
|
53
54
|
|
|
54
55
|
export type SuspenseListRevealOrder = "forwards" | "backwards" | "together" | "independent";
|
|
@@ -68,17 +69,19 @@ declare module "." {
|
|
|
68
69
|
children: Iterable<ReactElement> | AsyncIterable<ReactElement>;
|
|
69
70
|
/**
|
|
70
71
|
* Defines the order in which the `SuspenseList` children should be revealed.
|
|
72
|
+
* @default "forwards"
|
|
71
73
|
*/
|
|
72
|
-
revealOrder
|
|
74
|
+
revealOrder?: "forwards" | "backwards" | "unstable_legacy-backwards" | undefined;
|
|
73
75
|
/**
|
|
74
76
|
* Dictates how unloaded items in a SuspenseList is shown.
|
|
75
77
|
*
|
|
76
|
-
* - By default, `SuspenseList` will show all fallbacks in the list.
|
|
77
78
|
* - `collapsed` shows only the next fallback in the list.
|
|
78
79
|
* - `hidden` doesn't show any unloaded items.
|
|
79
80
|
* - `visible` shows all fallbacks in the list.
|
|
81
|
+
*
|
|
82
|
+
* @default "hidden"
|
|
80
83
|
*/
|
|
81
|
-
tail
|
|
84
|
+
tail?: SuspenseListTailMode | undefined;
|
|
82
85
|
}
|
|
83
86
|
|
|
84
87
|
interface NonDirectionalSuspenseListProps extends SuspenseListCommonProps {
|
|
@@ -86,7 +89,7 @@ declare module "." {
|
|
|
86
89
|
/**
|
|
87
90
|
* Defines the order in which the `SuspenseList` children should be revealed.
|
|
88
91
|
*/
|
|
89
|
-
revealOrder: Exclude<SuspenseListRevealOrder, DirectionalSuspenseListProps["revealOrder"]
|
|
92
|
+
revealOrder: Exclude<SuspenseListRevealOrder, DirectionalSuspenseListProps["revealOrder"]>;
|
|
90
93
|
/**
|
|
91
94
|
* The tail property is invalid when not using the `forwards` or `backwards` reveal orders.
|
|
92
95
|
*/
|