@types/react-dom 18.3.0 → 18.3.7

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.
@@ -5,11 +5,12 @@
5
5
  This package contains type definitions for react-dom (https://reactjs.org).
6
6
 
7
7
  # Details
8
- Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-dom.
8
+ Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-dom/v18.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Thu, 25 Apr 2024 20:07:03 GMT
12
- * Dependencies: [@types/react](https://npmjs.com/package/@types/react)
11
+ * Last updated: Wed, 30 Apr 2025 10:37:29 GMT
12
+ * Dependencies: none
13
+ * Peer dependencies: [@types/react](https://npmjs.com/package/@types/react)
13
14
 
14
15
  # Credits
15
16
  These definitions were written by [Asana](https://asana.com), [AssureSign](http://www.assuresign.com), [Microsoft](https://microsoft.com), [MartynasZilinskas](https://github.com/MartynasZilinskas), [Josh Rutherford](https://github.com/theruther4d), [Jessica Franco](https://github.com/Jessidhia), and [Sebastian Silbermann](https://github.com/eps1lon).
@@ -70,6 +70,7 @@ declare module "." {
70
70
  type?: string | undefined;
71
71
  nonce?: string | undefined;
72
72
  referrerPolicy?: ReferrerPolicy | undefined;
73
+ media?: string | undefined;
73
74
  }
74
75
  function preload(href: string, options?: PreloadOptions): void;
75
76
 
@@ -11,6 +11,7 @@ import {
11
11
  DOMAttributes,
12
12
  DOMElement,
13
13
  FunctionComponentElement,
14
+ Key,
14
15
  ReactElement,
15
16
  ReactInstance,
16
17
  ReactNode,
@@ -29,7 +30,7 @@ export function unmountComponentAtNode(container: Element | DocumentFragment): b
29
30
  export function createPortal(
30
31
  children: ReactNode,
31
32
  container: Element | DocumentFragment,
32
- key?: null | string,
33
+ key?: Key | null,
33
34
  ): ReactPortal;
34
35
 
35
36
  export const version: string;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/react-dom",
3
- "version": "18.3.0",
3
+ "version": "18.3.7",
4
4
  "description": "TypeScript definitions for react-dom",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-dom",
6
6
  "license": "MIT",
@@ -46,14 +46,14 @@
46
46
  "default": "./index.d.ts"
47
47
  }
48
48
  },
49
- "./client": {
49
+ "./canary": {
50
50
  "types": {
51
- "default": "./client.d.ts"
51
+ "default": "./canary.d.ts"
52
52
  }
53
53
  },
54
- "./canary": {
54
+ "./client": {
55
55
  "types": {
56
- "default": "./canary.d.ts"
56
+ "default": "./client.d.ts"
57
57
  }
58
58
  },
59
59
  "./server": {
@@ -79,9 +79,10 @@
79
79
  "directory": "types/react-dom"
80
80
  },
81
81
  "scripts": {},
82
- "dependencies": {
83
- "@types/react": "*"
82
+ "dependencies": {},
83
+ "peerDependencies": {
84
+ "@types/react": "^18.0.0"
84
85
  },
85
- "typesPublisherContentHash": "6e701783391e040466f55ff67d4efe35c3cbc5868b0a0937f1dfb8f63fce36fc",
86
- "typeScriptVersion": "4.7"
86
+ "typesPublisherContentHash": "091d1528d83863778f5cb9fbf6c81d6e64ed2394f4c3c73a57ed81d9871b4465",
87
+ "typeScriptVersion": "5.1"
87
88
  }
@@ -24,13 +24,18 @@ declare global {
24
24
  import { ReactNode } from "react";
25
25
  import { ErrorInfo } from "./client";
26
26
 
27
+ export type BootstrapScriptDescriptor = {
28
+ src: string;
29
+ integrity?: string | undefined;
30
+ crossOrigin?: string | undefined;
31
+ };
27
32
  export interface RenderToPipeableStreamOptions {
28
33
  identifierPrefix?: string;
29
34
  namespaceURI?: string;
30
35
  nonce?: string;
31
36
  bootstrapScriptContent?: string;
32
- bootstrapScripts?: string[];
33
- bootstrapModules?: string[];
37
+ bootstrapScripts?: Array<string | BootstrapScriptDescriptor>;
38
+ bootstrapModules?: Array<string | BootstrapScriptDescriptor>;
34
39
  progressiveChunkSize?: number;
35
40
  onShellReady?: () => void;
36
41
  onShellError?: (error: unknown) => void;
@@ -100,8 +105,8 @@ export interface RenderToReadableStreamOptions {
100
105
  namespaceURI?: string;
101
106
  nonce?: string;
102
107
  bootstrapScriptContent?: string;
103
- bootstrapScripts?: string[];
104
- bootstrapModules?: string[];
108
+ bootstrapScripts?: Array<string | BootstrapScriptDescriptor>;
109
+ bootstrapModules?: Array<string | BootstrapScriptDescriptor>;
105
110
  progressiveChunkSize?: number;
106
111
  signal?: AbortSignal;
107
112
  onError?: (error: unknown, errorInfo: ErrorInfo) => string | void;
File without changes
File without changes
File without changes
File without changes