File tree Expand file tree Collapse file tree 8 files changed +24
-20
lines changed Expand file tree Collapse file tree 8 files changed +24
-20
lines changed Original file line number Diff line number Diff line change @@ -32,4 +32,11 @@ type VoidOrUndefinedOnly = void | { [UNDEFINED_VOID_ONLY]: never };
3232
3333declare module "." {
3434 export function unstable_useCacheRefresh ( ) : ( ) => void ;
35+
36+ /**
37+ * Warning: Only available in development builds.
38+ *
39+ * @see {@link https://react.dev/reference/react/captureOwnerStack Reference docs }
40+ */
41+ function captureOwnerStack ( ) : string | null ;
3542}
Original file line number Diff line number Diff line change @@ -109,11 +109,6 @@ declare module "." {
109109 // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
110110 export function experimental_useEffectEvent < T extends Function > ( event : T ) : T ;
111111
112- /**
113- * Warning: Only available in development builds.
114- */
115- function captureOwnerStack ( ) : string | null ;
116-
117112 type Reference = object ;
118113 type TaintableUniqueValue = string | bigint | ArrayBufferView ;
119114 function experimental_taintUniqueValue (
Original file line number Diff line number Diff line change @@ -25,3 +25,8 @@ function useCacheTest() {
2525 refresh ( ( ) => "refresh" ) ;
2626 }
2727}
28+
29+ function ownerStacks ( ) {
30+ // $ExpectType string | null
31+ const ownerStack = React . captureOwnerStack ( ) ;
32+ }
Original file line number Diff line number Diff line change @@ -43,11 +43,6 @@ function suspenseTest() {
4343 < React . Suspense fallback = "Loading" > B</ React . Suspense >
4444</ React . unstable_SuspenseList > ;
4545
46- function ownerStacks ( ) {
47- // $ExpectType string | null
48- const ownerStack = React . captureOwnerStack ( ) ;
49- }
50-
5146function useEvent ( ) {
5247 // Implicit any
5348 // @ts -expect-error
Original file line number Diff line number Diff line change @@ -32,4 +32,11 @@ type VoidOrUndefinedOnly = void | { [UNDEFINED_VOID_ONLY]: never };
3232
3333declare module "." {
3434 export function unstable_useCacheRefresh ( ) : ( ) => void ;
35+
36+ /**
37+ * Warning: Only available in development builds.
38+ *
39+ * @see {@link https://react.dev/reference/react/captureOwnerStack Reference docs }
40+ */
41+ function captureOwnerStack ( ) : string | null ;
3542}
Original file line number Diff line number Diff line change @@ -109,11 +109,6 @@ declare module "." {
109109 // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
110110 export function experimental_useEffectEvent < T extends Function > ( event : T ) : T ;
111111
112- /**
113- * Warning: Only available in development builds.
114- */
115- function captureOwnerStack ( ) : string | null ;
116-
117112 type Reference = object ;
118113 type TaintableUniqueValue = string | bigint | ArrayBufferView ;
119114 function experimental_taintUniqueValue (
Original file line number Diff line number Diff line change @@ -25,3 +25,8 @@ function useCacheTest() {
2525 refresh ( ( ) => "refresh" ) ;
2626 }
2727}
28+
29+ function ownerStacks ( ) {
30+ // $ExpectType string | null
31+ const ownerStack = React . captureOwnerStack ( ) ;
32+ }
Original file line number Diff line number Diff line change @@ -43,11 +43,6 @@ function suspenseTest() {
4343 < React . Suspense fallback = "Loading" > B</ React . Suspense >
4444</ React . unstable_SuspenseList > ;
4545
46- function ownerStacks ( ) {
47- // $ExpectType string | null
48- const ownerStack = React . captureOwnerStack ( ) ;
49- }
50-
5146function useEvent ( ) {
5247 // Implicit any
5348 // @ts -expect-error
You can’t perform that action at this time.
0 commit comments