@solidjs/web 2.0.0-rc.2 → 2.0.0-rc.20
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.
- package/README.md +1 -1
- package/dist/server.dev.js +5065 -0
- package/dist/server.js +1757 -355
- package/dist/{server.cjs → server.observe.js} +1951 -558
- package/dist/{dev.cjs → web.dev.js} +945 -550
- package/dist/web.js +635 -332
- package/dist/{dev.js → web.observe.js} +688 -403
- package/frames/dist/assets.js +92 -0
- package/frames/dist/client.dev.js +1296 -1198
- package/frames/dist/client.js +1128 -1191
- package/frames/dist/client.observe.js +2041 -0
- package/frames/dist/regions.js +171 -0
- package/frames/dist/server.dev.js +2549 -0
- package/frames/dist/server.js +1688 -3005
- package/frames/dist/server.observe.js +2548 -0
- package/frames/dist/trace.js +45 -0
- package/frames/dist/wire.js +594 -0
- package/frames/package.json +2 -25
- package/package.json +244 -256
- package/performance-tracks/dist/performance-tracks.dev.js +679 -0
- package/performance-tracks/dist/performance-tracks.js +6 -0
- package/performance-tracks/dist/performance-tracks.observe.js +667 -0
- package/performance-tracks/package.json +7 -0
- package/performance-tracks/types/index.d.ts +69 -0
- package/serialization/decode/package.json +2 -15
- package/serialization/dist/decode.js +121 -25
- package/serialization/dist/serialization.js +242 -88
- package/serialization/package.json +2 -15
- package/serialization/types/index.d.ts +85 -158
- package/serialization/types/serializer-decode.d.ts +173 -114
- package/serialization/types/serializer.d.ts +109 -0
- package/server-functions/dist/client.dev.js +1462 -0
- package/server-functions/dist/client.js +667 -165
- package/server-functions/dist/client.observe.js +1441 -0
- package/server-functions/dist/rich-args.js +84 -1
- package/server-functions/dist/server.dev.js +2714 -297
- package/server-functions/dist/server.js +2595 -271
- package/server-functions/dist/server.observe.js +3594 -0
- package/server-functions/package.json +2 -35
- package/server-functions/rich-args/package.json +2 -15
- package/skills/server-components/SKILL.md +117 -0
- package/storage/package.json +2 -15
- package/types/client.d.ts +342 -288
- package/types/constants.d.ts +22 -0
- package/types/cookies.d.ts +32 -84
- package/types/diagnostics.d.ts +80 -0
- package/types/frames/assets-tier.d.ts +78 -0
- package/types/frames/client.d.ts +40 -1
- package/types/frames/frame-client.d.ts +443 -280
- package/types/frames/frame-container-plugin.d.ts +64 -0
- package/types/frames/frame-morph.d.ts +29 -0
- package/types/frames/frame-sink.d.ts +141 -161
- package/types/frames/frame-transport.d.ts +263 -184
- package/types/frames/regions-tier.d.ts +60 -0
- package/types/frames/serializer-decode.d.ts +241 -0
- package/types/frames/serializer.d.ts +85 -158
- package/types/frames/server.d.ts +2 -2
- package/types/frames/trace-tier.d.ts +2 -0
- package/types/frames/tree-rewrite.d.ts +39 -0
- package/types/frames/wire-tier.d.ts +169 -0
- package/types/head.d.ts +20 -0
- package/types/index.d.ts +98 -81
- package/types/index.server.d.ts +159 -0
- package/types/jsx.d.ts +49 -44
- package/types/observe.d.ts +535 -0
- package/types/reconcile.d.ts +1 -0
- package/types/render.d.ts +11 -0
- package/types/request-error-hook.d.ts +5 -0
- package/types/response.d.ts +95 -147
- package/types/serializer-decode.d.ts +173 -114
- package/types/serializer.d.ts +85 -158
- package/types/server-functions/argument-codec.d.ts +30 -0
- package/types/server-functions/client.d.ts +238 -223
- package/types/server-functions/flash.d.ts +28 -30
- package/types/server-functions/registry.d.ts +105 -0
- package/types/server-functions/rich-args.d.ts +1 -10
- package/types/server-functions/server.d.ts +539 -531
- package/types/server-functions/shared.d.ts +398 -425
- package/types/server-functions/uploads.d.ts +50 -0
- package/types/server-mock.d.ts +120 -13
- package/types/server-observe.d.ts +86 -0
- package/types/server.d.ts +571 -422
- package/types/trace.d.ts +127 -0
- package/LICENSE +0 -21
- package/dist/web.cjs +0 -2033
- package/frames/dist/client.cjs +0 -2002
- package/frames/dist/client.dev.cjs +0 -2022
- package/frames/dist/server.cjs +0 -3877
- package/serialization/dist/decode.cjs +0 -139
- package/serialization/dist/serialization.cjs +0 -261
- package/serialization/types-cjs/index.d.cts +0 -182
- package/serialization/types-cjs/package.json +0 -3
- package/serialization/types-cjs/serializer-decode.d.cts +0 -182
- package/server-functions/dist/client.cjs +0 -834
- package/server-functions/dist/rich-args.cjs +0 -11
- package/server-functions/dist/server.cjs +0 -1242
- package/server-functions/dist/server.dev.cjs +0 -1242
- package/storage/dist/storage.cjs +0 -12
- package/storage/types-cjs/index.d.cts +0 -28
- package/storage/types-cjs/package.json +0 -3
- package/types/core.d.ts +0 -9
- package/types-cjs/client.d.cts +0 -337
- package/types-cjs/cookies.d.cts +0 -93
- package/types-cjs/core.d.cts +0 -9
- package/types-cjs/frames/client.d.cts +0 -36
- package/types-cjs/frames/frame-client.d.cts +0 -356
- package/types-cjs/frames/frame-sink.d.cts +0 -194
- package/types-cjs/frames/frame-transport.d.cts +0 -222
- package/types-cjs/frames/serializer.d.cts +0 -182
- package/types-cjs/frames/server.d.cts +0 -52
- package/types-cjs/index.d.cts +0 -244
- package/types-cjs/jsx-properties.d.cts +0 -93
- package/types-cjs/jsx.d.cts +0 -4159
- package/types-cjs/package.json +0 -3
- package/types-cjs/response.d.cts +0 -174
- package/types-cjs/serializer-decode.d.cts +0 -182
- package/types-cjs/serializer.d.cts +0 -182
- package/types-cjs/server-functions/client.d.cts +0 -262
- package/types-cjs/server-functions/flash.d.cts +0 -38
- package/types-cjs/server-functions/rich-args.d.cts +0 -10
- package/types-cjs/server-functions/server.d.cts +0 -681
- package/types-cjs/server-functions/shared.d.cts +0 -523
- package/types-cjs/server-mock.d.cts +0 -286
- package/types-cjs/server.d.cts +0 -544
package/types/client.d.ts
CHANGED
|
@@ -1,199 +1,10 @@
|
|
|
1
|
+
import { getOwner, createComponent, untrack, merge as mergeProps } from "solid-js";
|
|
2
|
+
import type { ClientErrorHook, Owner } from "solid-js";
|
|
3
|
+
import { effect, memo } from "./render.js";
|
|
1
4
|
import { JSX } from "./jsx.js";
|
|
2
|
-
import type { RequestEventLocals } from "./server.js";
|
|
3
|
-
|
|
4
|
-
// custom renderers. Compiler/tooling surface; not for hand-written code.
|
|
5
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
6
|
-
export const DOMWithState: Record<string, Record<string, 1 | 2>>;
|
|
7
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
8
|
-
export const ChildProperties: Set<string>;
|
|
9
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
10
|
-
export const DelegatedEvents: Set<string>;
|
|
11
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
12
|
-
export const DOMElements: Set<string>;
|
|
13
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
14
|
-
export const SVGElements: Set<string>;
|
|
15
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
16
|
-
export const MathMLElements: Set<string>;
|
|
17
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
18
|
-
export const VoidElements: Set<string>;
|
|
19
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
20
|
-
export const RawTextElements: Set<string>;
|
|
21
|
-
/** Compiler/tooling table; not for hand-written code. @internal */
|
|
22
|
-
export const Namespaces: Record<string, string>;
|
|
23
|
-
|
|
5
|
+
import type { RequestEventLocals, HydrationWriter, HydrationValue, LinkClaimHandler } from "./server.js";
|
|
6
|
+
import type { TraceContext } from "./trace.js";
|
|
24
7
|
type MountableElement = Element | Document | ShadowRoot | DocumentFragment | Node;
|
|
25
|
-
export function render(
|
|
26
|
-
code: () => JSX.Element,
|
|
27
|
-
element: MountableElement,
|
|
28
|
-
init?: JSX.Element,
|
|
29
|
-
options?: { owner?: unknown }
|
|
30
|
-
): () => void;
|
|
31
|
-
/**
|
|
32
|
-
* Compiler-emitted primitive; not for hand-written code.
|
|
33
|
-
* @param flag
|
|
34
|
-
* - `undefined` — clone the template as-is (uses `cloneNode`).
|
|
35
|
-
* - `1` — use `document.importNode` instead of `cloneNode`.
|
|
36
|
-
* - `2` — the template html is wrapped; the outer tag is stripped at clone time.
|
|
37
|
-
* @internal
|
|
38
|
-
*/
|
|
39
|
-
export function template(html: string, flag?: 1 | 2): () => Element;
|
|
40
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
41
|
-
export function scope<T extends () => any>(fn: T): T;
|
|
42
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
43
|
-
export function effect<T>(fn: (prev?: T) => T, effect: (value: T, prev?: T) => void): void;
|
|
44
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
45
|
-
export function memo<T>(fn: () => T, equal: boolean): () => T;
|
|
46
|
-
/**
|
|
47
|
-
* Compiler-emitted primitive; not for hand-written code — import `untrack`
|
|
48
|
-
* from `solid-js` instead.
|
|
49
|
-
* @internal
|
|
50
|
-
*/
|
|
51
|
-
export function untrack<T>(fn: () => T): T;
|
|
52
|
-
/**
|
|
53
|
-
* Compiler-emitted primitive; not for hand-written code.
|
|
54
|
-
* @internal
|
|
55
|
-
*/
|
|
56
|
-
export function insert<T>(
|
|
57
|
-
parent: MountableElement,
|
|
58
|
-
accessor: (() => T) | T,
|
|
59
|
-
marker?: Node | null,
|
|
60
|
-
init?: JSX.Element,
|
|
61
|
-
options?: {
|
|
62
|
-
/**
|
|
63
|
-
* Live accessor for the slot's logical host in the source tree (portals).
|
|
64
|
-
* Each top-level node the slot manages is tagged with a `_$host` getter
|
|
65
|
-
* backed by this accessor so delegated events retarget correctly.
|
|
66
|
-
*/
|
|
67
|
-
host?: () => Node | null;
|
|
68
|
-
/** Defer the insert effect to the queue instead of running it inline. */
|
|
69
|
-
schedule?: boolean;
|
|
70
|
-
}
|
|
71
|
-
): JSX.Element;
|
|
72
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
73
|
-
export function createComponent<T>(Comp: (props: T) => JSX.Element, props: T): JSX.Element;
|
|
74
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
75
|
-
export function delegateEvents(eventNames: string[]): void;
|
|
76
|
-
/** Event-delegation plumbing (Portal/custom-root wiring). Integration plumbing. @internal */
|
|
77
|
-
export function registerDelegatedRoot(root: MountableElement): void;
|
|
78
|
-
/** Event-delegation plumbing (Portal/custom-root wiring). Integration plumbing. @internal */
|
|
79
|
-
export function unregisterDelegatedRoot(root: MountableElement): void;
|
|
80
|
-
/** Event-delegation plumbing (Portal/custom-root wiring). Integration plumbing. @internal */
|
|
81
|
-
export function registerDelegatedContainer(
|
|
82
|
-
container: MountableElement,
|
|
83
|
-
owner?: MountableElement
|
|
84
|
-
): void;
|
|
85
|
-
/** Event-delegation plumbing (Portal/custom-root wiring). Integration plumbing. @internal */
|
|
86
|
-
export function unregisterDelegatedContainer(
|
|
87
|
-
container: MountableElement,
|
|
88
|
-
owner?: MountableElement
|
|
89
|
-
): void;
|
|
90
|
-
/** Event-delegation plumbing (Portal/custom-root wiring). Integration plumbing. @internal */
|
|
91
|
-
export function getDelegatedRoot(node: MountableElement): MountableElement | undefined;
|
|
92
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
93
|
-
export function spread<T>(node: Element, accessor: T, skipChildren?: Boolean): void;
|
|
94
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
95
|
-
export function assign(
|
|
96
|
-
node: Element,
|
|
97
|
-
props: any,
|
|
98
|
-
skipChildren?: Boolean,
|
|
99
|
-
prevProps?: any,
|
|
100
|
-
skipRef?: Boolean
|
|
101
|
-
): void;
|
|
102
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
103
|
-
export function setAttribute(node: Element, name: string, value: string): void;
|
|
104
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
105
|
-
export function setAttributeNS(node: Element, namespace: string, name: string, value: string): void;
|
|
106
|
-
/**
|
|
107
|
-
* Register a consumer for compiler-emitted element claims. Compiled DOM
|
|
108
|
-
* output claims navigation-relevant elements (`a[href]`, `form[action]`) at
|
|
109
|
-
* creation, and compiler-owned writes to `href`/`action` re-invoke the same
|
|
110
|
-
* handlers — so handlers must be idempotent and must check the element's
|
|
111
|
-
* relevance themselves (rechecks can fire for any element whose
|
|
112
|
-
* `href`/`action` is written, e.g. `<link href>`). Handlers run under the
|
|
113
|
-
* reactive owner current at element creation; scope per-element state and
|
|
114
|
-
* cleanup through your own reactive system. Dormant until registered —
|
|
115
|
-
* without a handler the emitted claims are null checks. Returns an
|
|
116
|
-
* unregister function.
|
|
117
|
-
*
|
|
118
|
-
* Integration plumbing (routers register the consumer); not meant for
|
|
119
|
-
* application code.
|
|
120
|
-
* @internal
|
|
121
|
-
*/
|
|
122
|
-
export function registerElementClaim(handler: (element: Element) => void): () => void;
|
|
123
|
-
/**
|
|
124
|
-
* Claim `node` for registered consumers (see `registerElementClaim`).
|
|
125
|
-
* Emitted by the compiler at element creation; idempotent by contract.
|
|
126
|
-
* @internal
|
|
127
|
-
*/
|
|
128
|
-
export function claimElement<T extends Element>(node: T): T;
|
|
129
|
-
/**
|
|
130
|
-
* Sweep-claim every navigation-relevant element (`a[href]`, `form[action]`)
|
|
131
|
-
* in `root` — the subtree equivalent of the per-element `claimElement`
|
|
132
|
-
* compiled output emits, for content that becomes live DOM without compiled
|
|
133
|
-
* creation code (frame streams, adopted SSR ranges). Dormant without a
|
|
134
|
-
* registered consumer.
|
|
135
|
-
*
|
|
136
|
-
* Integration plumbing; not meant for application code.
|
|
137
|
-
* @internal
|
|
138
|
-
*/
|
|
139
|
-
export function claimElementTree<T extends Node>(root: T): T;
|
|
140
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
141
|
-
export function className(node: Element, value: JSX.ClassValue, prev?: JSX.ClassValue): void;
|
|
142
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
143
|
-
export function setProperty(node: Element, name: string, value: any): void;
|
|
144
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
145
|
-
export function setStyleProperty(node: Element, name: string, value: any): void;
|
|
146
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
147
|
-
export function addEvent(
|
|
148
|
-
node: Element,
|
|
149
|
-
name: string,
|
|
150
|
-
handler: EventListener | EventListenerObject | (EventListenerObject & AddEventListenerOptions),
|
|
151
|
-
delegate: boolean
|
|
152
|
-
): void;
|
|
153
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
154
|
-
export function style(
|
|
155
|
-
node: Element,
|
|
156
|
-
value: { [k: string]: string },
|
|
157
|
-
prev?: { [k: string]: string }
|
|
158
|
-
): void;
|
|
159
|
-
/**
|
|
160
|
-
* Compiler-emitted primitive; not for hand-written code — import `getOwner`
|
|
161
|
-
* from `solid-js` instead.
|
|
162
|
-
* @internal
|
|
163
|
-
*/
|
|
164
|
-
export function getOwner(): unknown;
|
|
165
|
-
/**
|
|
166
|
-
* Compiler-emitted prop-spread helper; not for hand-written code — import
|
|
167
|
-
* `merge` from `solid-js` instead.
|
|
168
|
-
* @internal
|
|
169
|
-
*/
|
|
170
|
-
export function mergeProps(...sources: unknown[]): unknown;
|
|
171
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
172
|
-
export function dynamicProperty(props: unknown, key: string): unknown;
|
|
173
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
174
|
-
export function applyRef<T extends Element = Element>(
|
|
175
|
-
r: ((element: NoInfer<T>) => void) | ((element: NoInfer<T>) => void)[],
|
|
176
|
-
element: T
|
|
177
|
-
): void;
|
|
178
|
-
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
179
|
-
export function ref(
|
|
180
|
-
fn: () => ((element: Element) => void) | ((element: Element) => void)[],
|
|
181
|
-
element: Element
|
|
182
|
-
): void;
|
|
183
|
-
|
|
184
|
-
export function hydrate(
|
|
185
|
-
fn: () => JSX.Element,
|
|
186
|
-
node: MountableElement,
|
|
187
|
-
options?: { renderId?: string; owner?: unknown }
|
|
188
|
-
): () => void;
|
|
189
|
-
/** Hydration-walk primitive; not for hand-written code. @internal */
|
|
190
|
-
export function getHydrationKey(): string | undefined;
|
|
191
|
-
/** Hydration-walk primitive; not for hand-written code. @internal */
|
|
192
|
-
export function getNextElement(template?: () => Element): Element;
|
|
193
|
-
/** Hydration-walk primitive; not for hand-written code. @internal */
|
|
194
|
-
export function getNextMatch(start: Node, elementName: string): Element;
|
|
195
|
-
/** Hydration-walk primitive; not for hand-written code. @internal */
|
|
196
|
-
export function getNextMarker(start: Node): [Node, Array<Node>];
|
|
197
8
|
/**
|
|
198
9
|
* A head tag descriptor. Props values may be getters (reactive on the
|
|
199
10
|
* client); `children` is the text body. `key` overrides the built-in dedupe
|
|
@@ -207,42 +18,30 @@ export function getNextMarker(start: Node): [Node, Array<Node>];
|
|
|
207
18
|
* read them from the getter. See docs/head-management-rfc.md.
|
|
208
19
|
*/
|
|
209
20
|
export type HeadTag = {
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
21
|
+
tag: "title" | "meta" | "link" | "style" | "script" | "base";
|
|
22
|
+
props: Record<string, any>;
|
|
23
|
+
key?: string | (() => string);
|
|
213
24
|
};
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
| { type: "module"; href: string }
|
|
228
|
-
| ExclusiveAssetDescriptor<any>;
|
|
25
|
+
export type AssetDescriptor = {
|
|
26
|
+
type: "style";
|
|
27
|
+
href: string;
|
|
28
|
+
attrs?: Record<string, string>;
|
|
29
|
+
} | {
|
|
30
|
+
type: "inline-style";
|
|
31
|
+
id: string;
|
|
32
|
+
content?: string;
|
|
33
|
+
attrs?: Record<string, string>;
|
|
34
|
+
} | {
|
|
35
|
+
type: "module";
|
|
36
|
+
href: string;
|
|
37
|
+
} | ExclusiveAssetDescriptor<any>;
|
|
229
38
|
export interface ExclusiveAssetDescriptor<T> {
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
39
|
+
policy: "exclusive";
|
|
40
|
+
key: string;
|
|
41
|
+
value: T;
|
|
42
|
+
get(): T;
|
|
43
|
+
set(value: T): void;
|
|
235
44
|
}
|
|
236
|
-
/**
|
|
237
|
-
* @internal Ref-counted client asset ownership: acquire adopts or mounts the
|
|
238
|
-
* asset, the returned release follows the owner (with a grace period for
|
|
239
|
-
* back-and-forth navigation). Internal machinery, not a public CSS-lifecycle
|
|
240
|
-
* API — per the head-management RFC (docs/head-management-rfc.md), ambient
|
|
241
|
-
* bundler-injected CSS is never lifecycle-managed, and the head registry
|
|
242
|
-
* owns the lifecycle of directly-mounted stylesheets outright. This keeps
|
|
243
|
-
* its non-head roles (exclusive slots, owner-following DOM ownership).
|
|
244
|
-
*/
|
|
245
|
-
export function acquireAsset(descriptor: AssetDescriptor): () => void;
|
|
246
45
|
/**
|
|
247
46
|
* Registry entry returned by `warmAsset`. Stylesheet entries carry load
|
|
248
47
|
* tracking for the client reveal gate (docs/client-css-reveal-gating.md):
|
|
@@ -250,38 +49,23 @@ export function acquireAsset(descriptor: AssetDescriptor): () => void;
|
|
|
250
49
|
* sheet releases the gate, parity with the server gate.
|
|
251
50
|
*/
|
|
252
51
|
export interface AssetEntry {
|
|
253
|
-
|
|
254
|
-
|
|
52
|
+
loadState?: "pending" | "loaded" | "errored";
|
|
53
|
+
loadPromise?: Promise<void>;
|
|
255
54
|
}
|
|
256
|
-
/**
|
|
257
|
-
* @internal Warm half of `acquireAsset`: idempotent and refcount-free,
|
|
258
|
-
* callable from a compute phase so the fetch starts at discovery and
|
|
259
|
-
* overlaps a transition's data wait. Stylesheets warm as
|
|
260
|
-
* `rel="preload" as="style"` and are flipped live by `acquireAsset` at
|
|
261
|
-
* commit — a branch superseded before it commits leaks only an inert
|
|
262
|
-
* preload, never an applied sheet. Only link-backed descriptors warm;
|
|
263
|
-
* inline styles and exclusive slots return `undefined`.
|
|
264
|
-
*/
|
|
265
|
-
export function warmAsset(descriptor: AssetDescriptor): AssetEntry | undefined;
|
|
266
|
-
export function HydrationScript(props?: { nonce?: string; eventNames?: string[] }): JSX.Element;
|
|
267
|
-
export function generateHydrationScript(options?: {
|
|
268
|
-
nonce?: string;
|
|
269
|
-
eventNames?: string[];
|
|
270
|
-
}): string;
|
|
271
55
|
/**
|
|
272
56
|
* See the server entry's `ResponseStub` — the shape of the mutable response
|
|
273
57
|
* head integrations expose as `event.response` via module augmentation.
|
|
274
58
|
*/
|
|
275
59
|
export interface ResponseStub {
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
60
|
+
status?: number;
|
|
61
|
+
statusText?: string;
|
|
62
|
+
headers: Headers;
|
|
63
|
+
/**
|
|
64
|
+
* Set by the integration once the response head has been derived/sent
|
|
65
|
+
* from this stub (status/headers can no longer change); consumers must
|
|
66
|
+
* treat later writes and cleanup-time retractions as no-ops.
|
|
67
|
+
*/
|
|
68
|
+
committed?: boolean;
|
|
285
69
|
}
|
|
286
70
|
/**
|
|
287
71
|
* See the server entry's `RequestEventLocals` — the augmentable type of
|
|
@@ -290,48 +74,318 @@ export interface ResponseStub {
|
|
|
290
74
|
* `locals`, whichever entry typed the event.
|
|
291
75
|
*/
|
|
292
76
|
export { RequestEventLocals } from "./server.js";
|
|
77
|
+
export type { HydrationWriter, HydrationValue, LinkClaimHandler } from "./server.js";
|
|
293
78
|
export interface RequestEvent {
|
|
294
|
-
|
|
295
|
-
|
|
79
|
+
request: Request;
|
|
80
|
+
locals: RequestEventLocals;
|
|
296
81
|
}
|
|
82
|
+
export type { CookieOptions } from "./cookies.js";
|
|
83
|
+
export type { CallEvent, CallListener, CallLive, CallRequestEvent, CallRequestListener, FrameAppliedEvent, FrameEvent, FrameListener, FrameLive, FrameProducedEvent, InvocationEvent, InvocationListener, InvocationLive, RenderEvent, RenderListener, RenderLive, RenderRoute } from "./observe.js";
|
|
84
|
+
export type { TraceContext, TraceProvider } from "./trace.js";
|
|
85
|
+
export type { ServerFunction, ServerFunctionMetadata, ServerFunctionRPC } from "./server-functions/shared.js";
|
|
86
|
+
export declare const waitAsset: (promise: Promise<unknown>) => void;
|
|
87
|
+
export { DOMWithState, ChildProperties, DOMElements, SVGElements, MathMLElements, VoidElements, RawTextElements, Namespaces, DelegatedEvents } from "./constants.js";
|
|
88
|
+
type CSPNonce = string | {
|
|
89
|
+
script: string | false;
|
|
90
|
+
style: string | false;
|
|
91
|
+
};
|
|
92
|
+
/** Client stub — hydration bootstrap is a server-only emit. */
|
|
93
|
+
export declare function generateHydrationScript(_options?: {
|
|
94
|
+
eventNames?: string[];
|
|
95
|
+
nonce?: CSPNonce;
|
|
96
|
+
}): string;
|
|
97
|
+
/** Client stub — valid JSX component, renders nothing. */
|
|
98
|
+
export declare function HydrationScript(_props?: {
|
|
99
|
+
nonce?: CSPNonce;
|
|
100
|
+
eventNames?: string[];
|
|
101
|
+
}): null;
|
|
102
|
+
export { effect, memo, untrack, getOwner, createComponent };
|
|
297
103
|
/**
|
|
298
|
-
*
|
|
299
|
-
*
|
|
300
|
-
*
|
|
301
|
-
* `getRequestEvent()` instead.
|
|
104
|
+
* Compiler-emitted prop-spread helper. The JSX transform emits
|
|
105
|
+
* `mergeProps(...)` when compiling prop spreads on components — not a
|
|
106
|
+
* user-facing API. Application code should import `merge` from `solid-js`.
|
|
302
107
|
* @internal
|
|
303
108
|
*/
|
|
304
|
-
export
|
|
305
|
-
export
|
|
109
|
+
export { mergeProps };
|
|
110
|
+
export declare const getRequestEvent: () => RequestEvent | undefined;
|
|
111
|
+
/** Client stub — values are written by the server render. See the server entry. */
|
|
112
|
+
export declare const getHydrationWriter: () => HydrationWriter | undefined;
|
|
306
113
|
/**
|
|
307
|
-
*
|
|
308
|
-
*
|
|
309
|
-
*
|
|
310
|
-
*
|
|
114
|
+
* Removes and returns the value the server render wrote under `key` with
|
|
115
|
+
* `getHydrationWriter().write(key, value)`, or `undefined` when the page
|
|
116
|
+
* carries none (or it was already taken). A written promise arrives as
|
|
117
|
+
* `"pending"` until its settlement streams in, then as `"resolved"` or
|
|
118
|
+
* `"rejected"`. Readable before `hydrate()` runs and after hydration has
|
|
119
|
+
* ended. Server: `undefined`.
|
|
120
|
+
*
|
|
121
|
+
* The page's values live on `globalThis._$HY.r`; a test seeds them with
|
|
122
|
+
* `globalThis._$HY = { r: { "sq:key": value } }`.
|
|
311
123
|
*/
|
|
124
|
+
export declare function takeHydrationValue<T = unknown>(key: string): HydrationValue<T> | undefined;
|
|
125
|
+
/**
|
|
126
|
+
* Client stub — a render's link handler is set during server rendering
|
|
127
|
+
* (see the server entry's `setLinkClaim`). Always `false` here, so a router
|
|
128
|
+
* can call it unguarded from isomorphic setup code.
|
|
129
|
+
* @internal
|
|
130
|
+
*/
|
|
131
|
+
export declare function setLinkClaim(_handler: LinkClaimHandler | undefined): boolean;
|
|
132
|
+
/**
|
|
133
|
+
* Whether the server render that produced this document ran a link handler
|
|
134
|
+
* (`setLinkClaim`), so its anchors carry the server's link state
|
|
135
|
+
* (`aria-current="page"`, `data-active`) in the HTML. Reads the `links`
|
|
136
|
+
* hydration record the render wrote once; non-destructive, readable before
|
|
137
|
+
* and after hydration. `false` on a page rendered without the router — the
|
|
138
|
+
* absence of link state on an anchor then means nothing, and a link
|
|
139
|
+
* consumer must resolve it itself. Server: `false`.
|
|
140
|
+
* @internal
|
|
141
|
+
*/
|
|
142
|
+
export declare function hasServerLinkState(): boolean;
|
|
143
|
+
/**
|
|
144
|
+
* Client stub — the trace a request belongs to is a server-side reading
|
|
145
|
+
* (the incoming `traceparent`, the render's origination); the browser SDK
|
|
146
|
+
* that continues it reads the document's `<meta>`/`Server-Timing` instead.
|
|
147
|
+
*/
|
|
148
|
+
export declare const getTraceContext: () => TraceContext | undefined;
|
|
312
149
|
export { parseCookieHeader, serializeCookie } from "./cookies.js";
|
|
313
|
-
export
|
|
150
|
+
export { clearFlashCookie, hasFlashCookie } from "./cookies.js";
|
|
151
|
+
export { getServerFunctionMetadata, getServerFunctionRPC, isServerFunction } from "./server-functions/registry.js";
|
|
152
|
+
/**
|
|
153
|
+
* Renders a component tree into a DOM element. Returns a dispose function
|
|
154
|
+
* that tears the tree down and cleans up reactive scopes when called.
|
|
155
|
+
*
|
|
156
|
+
* The top-level insert is queued via `{ schedule: true }` so its initial
|
|
157
|
+
* DOM attach goes through the effect queue rather than executing inline.
|
|
158
|
+
* This lets the mount participate in transitions: if an uncaught async
|
|
159
|
+
* read surfaces during the initial render (no `Loading` ancestor absorbs
|
|
160
|
+
* it), the mount is held by the transition and attaches atomically once
|
|
161
|
+
* all pending settles. On the no-async happy path the tail `flush()`
|
|
162
|
+
* drains the queued callback so the attach is synchronous by the time
|
|
163
|
+
* `render()` returns. The dev enforcement window scopes
|
|
164
|
+
* `ASYNC_OUTSIDE_LOADING_BOUNDARY` to the initial mount only.
|
|
165
|
+
*/
|
|
166
|
+
export declare function render(code: () => JSX.Element, element: MountableElement, init?: JSX.Element, options?: {
|
|
167
|
+
owner?: unknown;
|
|
168
|
+
renderId?: string;
|
|
169
|
+
/**
|
|
170
|
+
* This root's client error hook, ahead of `configureClientErrors`':
|
|
171
|
+
* every failure an error boundary under it renders a fallback for —
|
|
172
|
+
* the one event no global handler sees (an uncaught error halts the
|
|
173
|
+
* reactive system and reaches `reportError` / `window.onerror`). Once
|
|
174
|
+
* per error object; no return — the client has no wire to map for.
|
|
175
|
+
*/
|
|
176
|
+
onError?: ClientErrorHook;
|
|
177
|
+
}): () => void;
|
|
178
|
+
export declare function template(html: string, flag?: 1 | 2): () => Element;
|
|
179
|
+
export declare function delegateEvents(eventNames: string[]): void;
|
|
180
|
+
export declare function registerDelegatedRoot(root: MountableElement): void;
|
|
181
|
+
export declare function unregisterDelegatedRoot(root: MountableElement): void;
|
|
182
|
+
export declare function registerDelegatedContainer(container: MountableElement, owner?: MountableElement): void;
|
|
183
|
+
export declare function unregisterDelegatedContainer(container: MountableElement, owner?: MountableElement): void;
|
|
184
|
+
/**
|
|
185
|
+
* Runs `fn` as a handler of the DOM event `e`, inside the interaction frame
|
|
186
|
+
* the runtime opens for `e` — the one its own listeners for `e` run in. A
|
|
187
|
+
* listener the runtime did not attach (a router's `document` click handler,
|
|
188
|
+
* analytics, drag-and-drop) wraps its body in this, so its work joins the
|
|
189
|
+
* same interaction record as the component handlers for the same event
|
|
190
|
+
* instead of running outside one. In production builds this is `fn()`.
|
|
191
|
+
*
|
|
192
|
+
* Use it for listeners that respond to the user (`click`, `submit`,
|
|
193
|
+
* `keydown`), not for passive ones (`mousemove`, `focusin` preloads), which
|
|
194
|
+
* would each record an interaction.
|
|
195
|
+
*
|
|
196
|
+
* @example
|
|
197
|
+
* ```ts
|
|
198
|
+
* document.addEventListener("click", e =>
|
|
199
|
+
* dispatchAsInteraction(e, () => handleAnchorClick(e))
|
|
200
|
+
* );
|
|
201
|
+
* ```
|
|
202
|
+
*/
|
|
203
|
+
export declare function dispatchAsInteraction<T>(e: Event, fn: () => T): T;
|
|
204
|
+
export declare function getDelegatedRoot(node: MountableElement): MountableElement | undefined;
|
|
205
|
+
export declare function setProperty(node: Element, name: string, value: any): void;
|
|
206
|
+
/**
|
|
207
|
+
* A stateful DOM property write (`input.value`, `input.checked`,
|
|
208
|
+
* `option.selected`, `video.muted`, ...) from dev-compiled, non-hydratable
|
|
209
|
+
* DOM output: exactly `node[name] = value`, which is what production
|
|
210
|
+
* output inlines. The dev runtime checks it first and warns
|
|
211
|
+
* (`UNCOMMITTED_INPUT_OVERWRITTEN`) when it re-applies an unchanged bound
|
|
212
|
+
* value over an edit the user never committed to the signal. Production
|
|
213
|
+
* compile output never imports it, so it tree-shakes away.
|
|
214
|
+
*
|
|
215
|
+
* @internal Compiler output only.
|
|
216
|
+
*/
|
|
217
|
+
export declare function setStatefulProperty(node: Element, name: string, value: any): void;
|
|
218
|
+
/**
|
|
219
|
+
* Options for `registerElementClaim`.
|
|
220
|
+
* @internal
|
|
221
|
+
*/
|
|
222
|
+
export type ElementClaimOptions = {
|
|
223
|
+
/**
|
|
224
|
+
* Attribute names whose compiler-owned writes re-claim an already claimed
|
|
225
|
+
* element, as plain names: `href` covers the `href` attribute, the
|
|
226
|
+
* `prop:href` property path and the `xlink:href` namespaced path alike.
|
|
227
|
+
* Defaults to `["href", "action"]`. The write sites consult the union of
|
|
228
|
+
* every registered consumer's set.
|
|
229
|
+
*/
|
|
230
|
+
attributes?: readonly string[];
|
|
231
|
+
}; /**
|
|
232
|
+
* Register a consumer for compiler-emitted element claims. Compiled DOM
|
|
233
|
+
* output claims navigation-relevant elements (`a[href]`, `form[action]`)
|
|
234
|
+
* once at mount, after their initial attributes are applied — so a handler
|
|
235
|
+
* sees the element's final initial attributes and is told about one mount
|
|
236
|
+
* exactly once. Afterwards compiler-owned writes to an attribute in the
|
|
237
|
+
* consumer's declared set (`options.attributes`, default `href`/`action`;
|
|
238
|
+
* `prop:href` and `xlink:href` map to `href`) re-invoke the handlers — so
|
|
239
|
+
* handlers must be idempotent and must check the element's relevance
|
|
240
|
+
* themselves. Handlers run under the reactive owner the element was created
|
|
241
|
+
* with; scope per-element state and cleanup through your own reactive
|
|
242
|
+
* system. Dormant until registered — without a handler the emitted claims
|
|
243
|
+
* are null checks. Returns an unregister function.
|
|
244
|
+
*
|
|
245
|
+
* Integration plumbing (routers register the consumer); not meant for
|
|
246
|
+
* application code.
|
|
247
|
+
* @internal
|
|
248
|
+
*/
|
|
249
|
+
export declare function registerElementClaim(handler: (element: Element) => void, options?: ElementClaimOptions): () => void;
|
|
250
|
+
export declare function claimElementTree<T extends Node>(root: T): T;
|
|
251
|
+
export declare function claimElement<T extends Element>(node: T, owner?: Owner | null): T;
|
|
252
|
+
export declare function setAttribute(node: Element, name: string, value: string): void;
|
|
253
|
+
export declare function setAttributeNS(node: Element, namespace: string, name: string, value: string): void;
|
|
254
|
+
export declare function className(node: Element, value: JSX.ClassValue, prev?: JSX.ClassValue): void;
|
|
255
|
+
export declare function addEvent(node: Element, name: string, handler: EventListener | EventListenerObject | (EventListenerObject & AddEventListenerOptions), delegate: boolean): EventListener | EventListenerObject | void;
|
|
256
|
+
export declare function style(node: Element, value: {
|
|
257
|
+
[k: string]: string;
|
|
258
|
+
}, prev?: {
|
|
259
|
+
[k: string]: string;
|
|
260
|
+
}): void;
|
|
261
|
+
/** Compiler-emitted primitive; not for hand-written code. @internal
|
|
262
|
+
*
|
|
263
|
+
* Read an object-valued `style` / `class` binding ONE layer deep, TRACKED, in
|
|
264
|
+
* the compute half of its effect. (Not solid-js's `snapshot()`, which is a
|
|
265
|
+
* deep, untracked structural copy.) `style()` and `className()` enumerate their object in the
|
|
266
|
+
* effect's untracked commit phase, so a proxy-backed object (a store
|
|
267
|
+
* sub-object, merged props) was identity-reactive only: in-place key
|
|
268
|
+
* mutations never re-applied and every leaf read tripped
|
|
269
|
+
* STRICT_READ_UNTRACKED in dev. The compiler wraps the compute value of a
|
|
270
|
+
* non-inline `style={expr}` / `class={expr}` in this; spread() applies it to
|
|
271
|
+
* those two keys as it copies. Inline literals never get here — they compile
|
|
272
|
+
* per property. Identity passthrough for strings and plain objects (a fresh
|
|
273
|
+
* literal is already the compute's own); a proxy is copied with ONE
|
|
274
|
+
* `ownKeys` trap (its own trap keeps the key set tracked) plus one tracked
|
|
275
|
+
* read per key; a clsx-style class array is re-mapped element-wise (className
|
|
276
|
+
* allocates for an array anyway; measured at parity).
|
|
277
|
+
*
|
|
278
|
+
* The proxy's keys are read with `Reflect.ownKeys` directly — what
|
|
279
|
+
* `sourceKeys(value, SOURCE_PROXY)` resolves to by definition (`leafOf` is
|
|
280
|
+
* the identity for a proxy kind; `leafKeys` answers a proxy with one
|
|
281
|
+
* `ownKeys` trap) — rather than through `sourceKeys`, whose kind argument is
|
|
282
|
+
* a runtime value: calling it here retained the merge/omit view walkers
|
|
283
|
+
* (`collectKeys`, `mergeKeysOf`, `hiddenByAny`, …, ≈ 1.1 KB minified) on
|
|
284
|
+
* every compiled page with a dynamic `class`/`style`, reached by nothing
|
|
285
|
+
* (hydration-split-measured.md, candidate (e)). `spread()` still reads its
|
|
286
|
+
* sources through `sourceKeys`, so a page with an element spread keeps them. */
|
|
287
|
+
export declare function readShallow(value: unknown): unknown;
|
|
288
|
+
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
289
|
+
export declare function setStyleProperty(node: Element, name: string, value: any): void;
|
|
290
|
+
export declare function spread(node: Element, sources: unknown[], skipChildren?: Boolean, skip?: (key: string) => boolean, name?: string, loc?: string): void;
|
|
291
|
+
export declare function spread<T>(node: Element, accessor: T, skipChildren?: Boolean, skip?: (key: string) => boolean, name?: string, loc?: string): void;
|
|
292
|
+
export declare function dynamicProperty(props: unknown, key: string): unknown;
|
|
293
|
+
export declare function applyRef<T extends Element = Element>(r: ((element: NoInfer<T>) => void) | ((element: NoInfer<T>) => void)[], element: T): void;
|
|
294
|
+
export declare function ref(fn: () => ((element: Element) => void) | ((element: Element) => void)[], element: Element): void;
|
|
295
|
+
/** Compiler-emitted primitive; not for hand-written code. @internal */
|
|
296
|
+
export declare function scope<T extends () => any>(fn: T): T;
|
|
297
|
+
export declare function installHydrationRuntime(): void;
|
|
314
298
|
/**
|
|
315
|
-
*
|
|
316
|
-
*
|
|
317
|
-
* server-function layer (reference detection + the late-bound RPC seam).
|
|
318
|
-
* On the core entries so integrations consuming them eagerly (routers)
|
|
319
|
-
* never import the server-functions entry — whose client half is the
|
|
320
|
-
* transport + codec — from their eager graph. Declared through
|
|
321
|
-
* server-functions/shared.d.ts, the declaration home published-types
|
|
322
|
-
* layouts ship.
|
|
299
|
+
* Compiler-emitted primitive; not for hand-written code.
|
|
300
|
+
* @internal
|
|
323
301
|
*/
|
|
324
|
-
export {
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
302
|
+
export declare function insert<T>(parent: MountableElement, accessor: (() => T) | T, marker?: Node | null, init?: JSX.Element, options?: {
|
|
303
|
+
/**
|
|
304
|
+
* Live accessor for the slot's logical host in the source tree (portals).
|
|
305
|
+
* Each top-level node the slot manages is tagged with a `_$host` getter
|
|
306
|
+
* backed by this accessor so delegated events retarget correctly.
|
|
307
|
+
*/
|
|
308
|
+
host?: () => Node | null;
|
|
309
|
+
/** Defer the insert effect to the queue instead of running it inline. */
|
|
310
|
+
schedule?: boolean;
|
|
311
|
+
/**
|
|
312
|
+
* Label for the hole's render effects (the outer and, for a nested
|
|
313
|
+
* accessor, the inner unwrapping effect) — the compiler emits the parent
|
|
314
|
+
* tag as written under `sourceNames.bindings` (`div.children`). Dev and
|
|
315
|
+
* observe runtimes carry it on the node; production ignores it.
|
|
316
|
+
*/
|
|
317
|
+
name?: string;
|
|
318
|
+
/**
|
|
319
|
+
* Source location of the hole (`src/App.tsx:14:7`, root-relative
|
|
320
|
+
* `file:line:col`) — the compiler's `sourceNames` `locations` kind. Dev
|
|
321
|
+
* and observe runtimes carry it on the node for console reports and
|
|
322
|
+
* diagnostic events; production ignores it.
|
|
323
|
+
*/
|
|
324
|
+
loc?: string;
|
|
325
|
+
}): JSX.Element;
|
|
326
|
+
export declare function assign(node: Element, props: any, skipChildren?: Boolean, prevProps?: any, skipRef?: Boolean): void;
|
|
327
|
+
export declare function warmAsset(descriptor: AssetDescriptor): AssetEntry | undefined;
|
|
328
|
+
export declare function acquireAsset(descriptor: AssetDescriptor): () => void;
|
|
329
|
+
export declare function useHead(tag: HeadTag | HeadTag[] | (() => HeadTag | HeadTag[])): void;
|
|
330
|
+
/**
|
|
331
|
+
* Resumes a server-rendered tree on the client, attaching event listeners
|
|
332
|
+
* and reactive bindings without reconstructing the DOM. Returns a `dispose`
|
|
333
|
+
* function that tears down reactive scopes (DOM nodes are left in place).
|
|
334
|
+
*
|
|
335
|
+
* Use this when the page HTML was produced by `renderToString` or
|
|
336
|
+
* `renderToStream`. For client-only apps, use `render` instead.
|
|
337
|
+
*
|
|
338
|
+
* Pass `options.renderId` to hydrate one of multiple roots emitted by a
|
|
339
|
+
* server render that used the same id.
|
|
340
|
+
*
|
|
341
|
+
* When the server renders a full document but the client hydrates only the
|
|
342
|
+
* app subtree, the server must give that subtree its own id namespace: wrap
|
|
343
|
+
* the document shell in `<NoHydration>` and re-enter with `<Hydration>`
|
|
344
|
+
* around the app. Otherwise the app's hydration ids are allocated under the
|
|
345
|
+
* document component's owner tree and this walk can never claim them.
|
|
346
|
+
*/
|
|
347
|
+
export declare function hydrate(fn: () => JSX.Element, node: MountableElement, options?: {
|
|
348
|
+
renderId?: string;
|
|
349
|
+
owner?: unknown;
|
|
350
|
+
onError?: ClientErrorHook;
|
|
351
|
+
}): () => void;
|
|
352
|
+
export declare function getNextElement(template?: () => Element): Element;
|
|
353
|
+
export declare function getNextMatch(start: Node, elementName: string): Element;
|
|
354
|
+
export declare function getNextMarker(start: Node): [Node, Array<Node>];
|
|
355
|
+
export declare function getFirstChild(node: any, expectedTag: any): any;
|
|
356
|
+
export declare function getNextSibling(node: any, expectedTag: any): any;
|
|
357
|
+
export declare function runHydrationEvents(): void;
|
|
358
|
+
/**
|
|
359
|
+
* Installs the server-component half of hydration — solid's
|
|
360
|
+
* (`enableServerComponentHydration`: the hold, the claim window, fragment
|
|
361
|
+
* ownership, the ledger's published answer) and this runtime's two terms of
|
|
362
|
+
* the claim walk:
|
|
363
|
+
*
|
|
364
|
+
* - `sharedConfig.claimRoots` (ruling 95): a claimed tree isn't always IN
|
|
365
|
+
* the document — a frame adoption whose slot fill resolved async claims
|
|
366
|
+
* its server-rendered range after a pending boundary displaced it
|
|
367
|
+
* (re-inserted on reveal). Such claim scopes declare their roots, and
|
|
368
|
+
* descent from one is as claimed as being connected; fresh clones
|
|
369
|
+
* descend from neither.
|
|
370
|
+
* - The root sweep's frame exclusion (ruling 97): frame regions
|
|
371
|
+
* (`data-fid` — the frame runtime's element brand, an importless
|
|
372
|
+
* duplicate like FRAME_ID_ATTR in frame-client/frame-sink) are another
|
|
373
|
+
* layer's property. Their fills claim through their own windows on their
|
|
374
|
+
* own schedule (a lazy route module may adopt long after the root
|
|
375
|
+
* completes), so collecting them in the ambient sweep only sets up the
|
|
376
|
+
* completion sweep to report legitimately-late claims as unclaimed.
|
|
377
|
+
* Whether the root has frames is one question about the page, not one
|
|
378
|
+
* per keyed node: found once per sweep, containment-tested against the
|
|
379
|
+
* list rather than `closest("[data-fid]")` from every node.
|
|
380
|
+
*
|
|
381
|
+
* The same shape as `hydrate()` — solid's half, then this runtime's — one
|
|
382
|
+
* call for the integration. Before `hydrate()` runs its root sweep (the
|
|
383
|
+
* frames client calls it from `installServerComponents()`, which precedes
|
|
384
|
+
* `hydrate()` in every entry) and again wherever it re-attempts its reveal
|
|
385
|
+
* hook; idempotent. Cross-package wiring; not for application code.
|
|
386
|
+
*
|
|
387
|
+
* @internal
|
|
388
|
+
*/
|
|
389
|
+
export declare function installServerComponentHydration(): void;
|
|
390
|
+
export declare function getHydrationKey(): string | undefined;
|
|
391
|
+
export declare const RequestContext: unique symbol;
|