@solidjs/web 2.0.0-beta.3 → 2.0.0-beta.30

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.
Files changed (73) hide show
  1. package/README.md +27 -4
  2. package/dist/dev.cjs +1211 -205
  3. package/dist/dev.js +1175 -199
  4. package/dist/server.cjs +1342 -234
  5. package/dist/server.js +1304 -231
  6. package/dist/web.cjs +1195 -196
  7. package/dist/web.js +1159 -190
  8. package/frames/dist/client.cjs +1746 -0
  9. package/frames/dist/client.dev.cjs +1759 -0
  10. package/frames/dist/client.dev.js +1747 -0
  11. package/frames/dist/client.js +1734 -0
  12. package/frames/dist/server.cjs +2426 -0
  13. package/frames/dist/server.js +2414 -0
  14. package/frames/package.json +30 -0
  15. package/package.json +287 -38
  16. package/serialization/dist/serialization.cjs +169 -0
  17. package/serialization/dist/serialization.js +159 -0
  18. package/serialization/package.json +20 -0
  19. package/serialization/types/index.d.ts +157 -0
  20. package/serialization/types-cjs/index.d.cts +157 -0
  21. package/serialization/types-cjs/package.json +3 -0
  22. package/server-functions/dist/client.cjs +613 -0
  23. package/server-functions/dist/client.js +585 -0
  24. package/server-functions/dist/server.cjs +904 -0
  25. package/server-functions/dist/server.js +875 -0
  26. package/server-functions/package.json +30 -0
  27. package/storage/package.json +8 -3
  28. package/storage/types/index.d.ts +26 -0
  29. package/storage/types-cjs/index.d.cts +28 -0
  30. package/storage/types-cjs/package.json +3 -0
  31. package/types/client.d.ts +125 -21
  32. package/types/core.d.ts +4 -3
  33. package/types/frames/client.d.ts +20 -0
  34. package/types/frames/frame-client.d.ts +270 -0
  35. package/types/frames/frame-sink.d.ts +168 -0
  36. package/types/frames/frame-transport.d.ts +196 -0
  37. package/types/frames/serializer.d.ts +157 -0
  38. package/types/frames/server.d.ts +30 -0
  39. package/types/index.d.ts +211 -26
  40. package/types/jsx-properties.d.ts +93 -0
  41. package/types/jsx.d.ts +4150 -1
  42. package/types/response.d.ts +129 -0
  43. package/types/serializer.d.ts +157 -0
  44. package/types/server-functions/client.d.ts +200 -0
  45. package/types/server-functions/flash.d.ts +38 -0
  46. package/types/server-functions/server.d.ts +490 -0
  47. package/types/server-functions/shared.d.ts +445 -0
  48. package/types/server-mock.d.ts +93 -0
  49. package/types/server.d.ts +221 -28
  50. package/types-cjs/client.d.cts +192 -0
  51. package/types-cjs/core.d.cts +4 -0
  52. package/types-cjs/frames/client.d.cts +20 -0
  53. package/types-cjs/frames/frame-client.d.cts +270 -0
  54. package/types-cjs/frames/frame-sink.d.cts +168 -0
  55. package/types-cjs/frames/frame-transport.d.cts +196 -0
  56. package/types-cjs/frames/serializer.d.cts +157 -0
  57. package/types-cjs/frames/server.d.cts +30 -0
  58. package/types-cjs/index.d.cts +231 -0
  59. package/types-cjs/jsx-properties.d.cts +93 -0
  60. package/types-cjs/jsx.d.cts +4150 -0
  61. package/types-cjs/package.json +3 -0
  62. package/types-cjs/response.d.cts +129 -0
  63. package/types-cjs/serializer.d.cts +157 -0
  64. package/types-cjs/server-functions/client.d.cts +200 -0
  65. package/types-cjs/server-functions/flash.d.cts +38 -0
  66. package/types-cjs/server-functions/server.d.cts +490 -0
  67. package/types-cjs/server-functions/shared.d.cts +445 -0
  68. package/types-cjs/server-mock.d.cts +165 -0
  69. package/types-cjs/server.d.cts +349 -0
  70. package/storage/types/src/client.d.ts +0 -1
  71. package/storage/types/src/index.d.ts +0 -46
  72. package/storage/types/src/server-mock.d.ts +0 -72
  73. package/storage/types/storage/src/index.d.ts +0 -2
@@ -0,0 +1,349 @@
1
+ import { JSX } from "./jsx.cjs";
2
+ import { SerializerPlugin } from "./serializer.cjs";
3
+ export const DOMWithState: Record<string, Record<string, 1 | 2>>;
4
+ export const ChildProperties: Set<string>;
5
+ export const DelegatedEvents: Set<string>;
6
+ export const DOMElements: Set<string>;
7
+ export const SVGElements: Set<string>;
8
+ export const MathMLElements: Set<string>;
9
+ export const VoidElements: Set<string>;
10
+ export const RawTextElements: Set<string>;
11
+ export const Namespaces: Record<string, string>;
12
+
13
+ type MountableElement = Element | Document | ShadowRoot | DocumentFragment | Node;
14
+
15
+ /** Static asset manifest produced by a build (e.g. parsed Vite manifest.json). */
16
+ export type AssetManifest = Record<
17
+ string,
18
+ { file: string; css?: string[]; isEntry?: boolean; imports?: string[] }
19
+ > & { _base?: string };
20
+
21
+ /** Inline style content, e.g. dev CSS collected from a bundler's module graph. */
22
+ export type InlineStyleAsset = {
23
+ id: string;
24
+ content: string;
25
+ attrs?: Record<string, string>;
26
+ };
27
+
28
+ export type ResolvedAssets = {
29
+ js: string[];
30
+ css: (string | InlineStyleAsset)[];
31
+ };
32
+
33
+ /**
34
+ * Resolver form of the manifest option — the primitive a dev server
35
+ * implements against its live module graph (a static manifest object is
36
+ * normalized into a sync resolver internally). `resolve` may return a
37
+ * promise (async resolvers require streaming rendering); CSS entries may be
38
+ * URL strings (emitted as load-gated `<link>` tags) or inline-style
39
+ * descriptors (emitted as `<style>` tags). A bare `resolve`-shaped function
40
+ * is accepted as shorthand for `{ resolve }`.
41
+ */
42
+ export type AssetResolver = {
43
+ resolve(
44
+ key: string
45
+ ): ResolvedAssets | null | undefined | Promise<ResolvedAssets | null | undefined>;
46
+ /**
47
+ * Synchronous fast path answering with whatever is knowable without async
48
+ * work (typically js URLs, omitting css). Sync consumers — e.g. a lazy
49
+ * component's `moduleUrl` getter used by islands — use this when `resolve`
50
+ * would return a promise, so adapters should provide it whenever possible.
51
+ */
52
+ resolveSync?(key: string): ResolvedAssets | null | undefined;
53
+ };
54
+
55
+ /** Bare-function shorthand for `AssetResolver` (no sync fast path). */
56
+ export type AssetResolverFn = (
57
+ key: string
58
+ ) => ResolvedAssets | null | undefined | Promise<ResolvedAssets | null | undefined>;
59
+
60
+ export function renderToString<T>(
61
+ fn: () => T,
62
+ options?: {
63
+ nonce?: string;
64
+ renderId?: string;
65
+ noScripts?: boolean;
66
+ plugins?: SerializerPlugin[];
67
+ manifest?: AssetManifest | AssetResolver | AssetResolverFn;
68
+ onError?: (err: any) => void;
69
+ /**
70
+ * Embedded-render contract for hosts that own the document. When the
71
+ * render output contains no `</head>`, everything head-bound (resolved
72
+ * `useHead` winners, eager resources, tracked asset links, inline
73
+ * styles) is delivered here as one HTML string — prelude (charset/base)
74
+ * first — for the host to splice into its own `<head>` template, instead
75
+ * of being dropped. Called synchronously before `renderToString`
76
+ * returns; not called when the output has a `</head>` (splicing is
77
+ * automatic then).
78
+ */
79
+ onHead?: (head: string) => void;
80
+ }
81
+ ): string;
82
+ /** @deprecated use renderToStream which also returns a promise */
83
+ export function renderToStringAsync<T>(
84
+ fn: () => T,
85
+ options?: {
86
+ timeoutMs?: number;
87
+ nonce?: string;
88
+ renderId?: string;
89
+ noScripts?: boolean;
90
+ plugins?: SerializerPlugin[];
91
+ manifest?: AssetManifest | AssetResolver | AssetResolverFn;
92
+ onError?: (err: any) => void;
93
+ }
94
+ ): Promise<string>;
95
+ export function renderToStream<T>(
96
+ fn: () => T,
97
+ options?: {
98
+ nonce?: string;
99
+ renderId?: string;
100
+ noScripts?: boolean;
101
+ plugins?: SerializerPlugin[];
102
+ manifest?: AssetManifest | AssetResolver | AssetResolverFn;
103
+ onCompleteShell?: (info: { write: (v: string) => void }) => void;
104
+ onCompleteAll?: (info: { write: (v: string) => void }) => void;
105
+ onError?: (err: any) => void;
106
+ /**
107
+ * Embedded-render contract for hosts that own the document. When the
108
+ * shell contains no `</head>`, everything head-bound at first flush
109
+ * (resolved `useHead` winners, eager resources, tracked asset links,
110
+ * inline styles) is delivered here as one HTML string — prelude first —
111
+ * before the shell chunk is emitted, so the host can write its own
112
+ * `<head>` ahead of piping the stream. Post-shell head updates flow
113
+ * through the stream itself and apply in the browser. Not called when
114
+ * the shell has a `</head>` (splicing is automatic then).
115
+ */
116
+ onHead?: (head: string) => void;
117
+ }
118
+ ): {
119
+ then: (fn: (html: string) => void) => void;
120
+ pipe: (writable: { write: (v: string) => void; end: () => void }) => void;
121
+ pipeTo: (writable: WritableStream) => Promise<void>;
122
+ /**
123
+ * Lazy `ReadableStream<Uint8Array>` view of the render — hand it straight
124
+ * to `new Response(stream.readable)`. First access starts the render
125
+ * piping through an internal `TransformStream` (chunks are UTF-8 encoded
126
+ * bytes, the same as `pipeTo` writes) and the stream is cached, so
127
+ * repeated access returns the same instance. Like `pipe`/`pipeTo`, this
128
+ * consumes the render: use exactly one of the three — mixing distinct
129
+ * consumers (`readable` after `pipe`/`pipeTo`, or vice versa) throws an
130
+ * error naming the conflict.
131
+ */
132
+ readonly readable: ReadableStream<Uint8Array>;
133
+ };
134
+
135
+ export function HydrationScript(props: { nonce?: string; eventNames?: string[] }): JSX.Element;
136
+ export function ssr(template: string[] | string, ...nodes: any[]): { t: string };
137
+ export function ssrElement(
138
+ name: string,
139
+ props: any,
140
+ children: any,
141
+ needsId: boolean
142
+ ): { t: string };
143
+ export function ssrClassName(value: string | { [k: string]: boolean } | Array<any>): string;
144
+ export function ssrStyle(value: string | { [k: string]: string }): string;
145
+ export function ssrStyleProperty(name: string, value: any): string;
146
+ export function ssrAttribute(key: string, value: any): string;
147
+ export function ssrGroup<T extends () => any[]>(fn: T, n: number): T;
148
+ export function scope<T>(fn: () => T): () => unknown;
149
+ export function ssrHydrationKey(): string;
150
+ export function resolveSSRNode(node: any, result?: any, top?: boolean): any;
151
+ export function escape(s: any, attr?: boolean): any;
152
+ export function applyRef(
153
+ r: ((element: any) => void) | ((element: any) => void)[],
154
+ element: any
155
+ ): void;
156
+ /** @deprecated Use `useHead` — removed before `0.50.0` stable. */
157
+ export function useAssets(fn: () => JSX.Element): void;
158
+ /**
159
+ * @deprecated Use the `onHead` render option — removed before `0.50.0`
160
+ * stable. Reads ambient render state, so it is unsafe across concurrent
161
+ * renders; `onHead` is closure-bound to its render and also carries
162
+ * `useHead` output, which this does not.
163
+ */
164
+ export function getAssets(): string;
165
+ /**
166
+ * A head tag descriptor. Props values may be getters (evaluated lazily on
167
+ * the server — at the owning flush boundary — and reactively on the client);
168
+ * `children` is the text body (title text, inline style/script content).
169
+ * `key` overrides the built-in dedupe identity (`title` is a hard singleton
170
+ * that `key` cannot fork).
171
+ */
172
+ export type HeadTag = {
173
+ tag: "title" | "meta" | "link" | "style" | "script" | "base";
174
+ props: Record<string, any>;
175
+ key?: string | (() => string);
176
+ };
177
+ /**
178
+ * Registers head tags with the render's head registry. An array is a group —
179
+ * one replacement set; a single tag is a group of one. Replaceable tags
180
+ * (title/meta/canonical/…) resolve by last-committed group and stream as
181
+ * patches with their suspense boundary's reveal; resource tags (preload and
182
+ * friends, stylesheets, `script[src]`) emit eagerly and dedupe by identity.
183
+ * See docs/head-management-rfc.md.
184
+ */
185
+ export function useHead(tag: HeadTag | HeadTag[]): void;
186
+ export function getHydrationKey(): string | undefined;
187
+ export function effect<T>(fn: (prev?: T) => T, effect: (value: T, prev?: T) => void): void;
188
+ export function memo<T>(fn: () => T, equal: boolean): () => T;
189
+ export function createComponent<T>(Comp: (props: T) => JSX.Element, props: T): JSX.Element;
190
+ export function mergeProps(...sources: unknown[]): unknown;
191
+ export function getOwner(): unknown;
192
+ export function generateHydrationScript(options?: {
193
+ nonce?: string;
194
+ eventNames?: string[];
195
+ }): string;
196
+ /**
197
+ * Registered symbol (`Symbol.for("solid.RequestContext")`) naming the
198
+ * global slot where `provideRequestEvent` parks the AsyncLocalStorage that
199
+ * scopes request events. Integration plumbing — application code reads the
200
+ * event through `getRequestEvent()` instead.
201
+ * @internal
202
+ */
203
+ export declare const RequestContext: unique symbol;
204
+ /**
205
+ * The mutable response head an integration's handler exposes on the request
206
+ * event as `event.response`: status/statusText/headers it will apply when
207
+ * sending the response. A scaffold, not a `Response` — application code
208
+ * (e.g. JSX response components) writes to it during render, and the
209
+ * handler reads it when the head goes out. Core does not declare the
210
+ * `response` property on `RequestEvent` itself: integrations that provide
211
+ * one declare it through module augmentation (as `@solidjs/router` does),
212
+ * and this type names the shape they agree on. Core's server-function
213
+ * handler reads its `Set-Cookie` headers when folding single-flight
214
+ * cookies but never requires it.
215
+ */
216
+ export interface ResponseStub {
217
+ status?: number;
218
+ statusText?: string;
219
+ headers: Headers;
220
+ /**
221
+ * Set by the integration once the response head has been derived/sent
222
+ * from this stub — status and headers can no longer change. Consumers
223
+ * that write response metadata during render (e.g. JSX response
224
+ * components) must treat later status/header writes and cleanup-time
225
+ * retractions as no-ops.
226
+ */
227
+ committed?: boolean;
228
+ }
229
+
230
+ /**
231
+ * The per-request context available on the server: the incoming `Request`
232
+ * and a `locals` bag integrations and middleware can hang state on.
233
+ * Frameworks typically extend this shape with richer fields (e.g. a
234
+ * `response` head — see `ResponseStub`).
235
+ */
236
+ export interface RequestEvent {
237
+ request: Request;
238
+ locals: Record<string | number | symbol, any>;
239
+ }
240
+ /**
241
+ * The current request event, when called on the server inside a request
242
+ * scope (established by `provideRequestEvent` from `@solidjs/web/storage`
243
+ * or by the framework). Undefined on the client and outside a request.
244
+ * Read it above `await` boundaries in partially-polyfilled environments.
245
+ */
246
+ export function getRequestEvent(): RequestEvent | undefined;
247
+
248
+ export function Assets(props: { children?: JSX.Element }): JSX.Element;
249
+ export function untrack<T>(fn: () => T): T;
250
+
251
+ // client-only APIs
252
+
253
+ /** @deprecated not supported on the server side */
254
+ export function style(
255
+ node: Element,
256
+ value: { [k: string]: string },
257
+ prev?: { [k: string]: string }
258
+ ): void;
259
+
260
+ /** @deprecated not supported on the server side */
261
+ export function insert<T>(
262
+ parent: MountableElement,
263
+ accessor: (() => T) | T,
264
+ marker?: Node | null,
265
+ init?: JSX.Element
266
+ ): JSX.Element;
267
+
268
+ /** @deprecated not supported on the server side */
269
+ export function spread<T>(node: Element, accessor: T, skipChildren?: Boolean): void;
270
+
271
+ /** @deprecated not supported on the server side */
272
+ export function delegateEvents(eventNames: string[]): void;
273
+ /** @deprecated not supported on the server side */
274
+ export function registerDelegatedRoot(root: MountableElement): void;
275
+ /** @deprecated not supported on the server side */
276
+ export function unregisterDelegatedRoot(root: MountableElement): void;
277
+ /** @deprecated not supported on the server side */
278
+ export function registerDelegatedContainer(
279
+ container: MountableElement,
280
+ owner?: MountableElement
281
+ ): void;
282
+ /** @deprecated not supported on the server side */
283
+ export function unregisterDelegatedContainer(
284
+ container: MountableElement,
285
+ owner?: MountableElement
286
+ ): void;
287
+ /** @deprecated not supported on the server side */
288
+ export function getDelegatedRoot(node: MountableElement): MountableElement | undefined;
289
+ /** @deprecated not supported on the server side */
290
+ export function dynamicProperty(props: unknown, key: string): unknown;
291
+ /** @deprecated not supported on the server side */
292
+ export function setAttribute(node: Element, name: string, value: string): void;
293
+ /** @deprecated not supported on the server side */
294
+ export function setAttributeNS(node: Element, namespace: string, name: string, value: string): void;
295
+
296
+ /**
297
+ * Server no-op: element claims are a client-only concern, but consumers may
298
+ * register isomorphically. Returns a no-op unregister function.
299
+ */
300
+ export function registerElementClaim(handler: (element: Element) => void): () => void;
301
+ /** Server no-op: returns `node` unchanged. Claims never fire during SSR. */
302
+ export function claimElement<T extends Element>(node: T): T;
303
+ /** Server no-op: returns `root` unchanged. Claims never fire during SSR. */
304
+ export function claimElementTree<T extends Node>(root: T): T;
305
+
306
+ /** @deprecated not supported on the server side */
307
+ export function addEvent(node: Element, name: string, handler: () => void, delegate: boolean): void;
308
+
309
+ /** @deprecated not supported on the server side */
310
+ export function render(code: () => JSX.Element, element: MountableElement): () => void;
311
+ /**
312
+ * @deprecated not supported on the server side
313
+ * @param flag
314
+ * - `undefined` — clone the template as-is (uses `cloneNode`).
315
+ * - `1` — use `document.importNode` instead of `cloneNode`.
316
+ * - `2` — the template html is wrapped; the outer tag is stripped at clone time.
317
+ */
318
+ export function template(html: string, flag?: 1 | 2): () => Element;
319
+ /** @deprecated not supported on the server side */
320
+ export function setProperty(node: Element, name: string, value: any): void;
321
+ /** @deprecated not supported on the server side */
322
+ export function className(node: Element, value: string): void;
323
+ /** @deprecated not supported on the server side */
324
+ export function assign(node: Element, props: any, skipChildren?: Boolean): void;
325
+
326
+ /** @deprecated not supported on the server side */
327
+ export function hydrate(
328
+ fn: () => JSX.Element,
329
+ node: MountableElement,
330
+ options?: { renderId?: string; owner?: unknown }
331
+ ): () => void;
332
+
333
+ /** @deprecated not supported on the server side */
334
+ export function getNextElement(template?: () => Element): Element;
335
+ /** @deprecated not supported on the server side */
336
+ export function getNextMatch(start: Node, elementName: string): Element;
337
+ /** @deprecated not supported on the server side */
338
+ export function getNextMarker(start: Node): [Node, Array<Node>];
339
+ /** @deprecated not supported on the server side */
340
+ export function runHydrationEvents(): void;
341
+ /** @deprecated not supported on the server side */
342
+ export function ref(
343
+ fn: () => ((element: Element) => void) | ((element: Element) => void)[],
344
+ element: Element
345
+ ): void;
346
+ /** @deprecated not supported on the server side */
347
+ export function setStyleProperty(node: Element, name: string, value: any): void;
348
+ /** @deprecated not supported on the server side — register assets through the render context instead */
349
+ export function acquireAsset(descriptor: unknown): () => void;
@@ -1 +0,0 @@
1
- export * from "dom-expressions/src/client.js";
@@ -1,46 +0,0 @@
1
- import { hydrate as hydrateCore, render as renderCore } from "./client.js";
2
- import { JSX, ComponentProps, ValidComponent } from "solid-js";
3
- export * from "./client.js";
4
- export declare function render(...args: Parameters<typeof renderCore>): ReturnType<typeof renderCore>;
5
- export { For, Show, Switch, Match, Errored, Loading, NoHydration, Hydration, merge as mergeProps } from "solid-js";
6
- export * from "./server-mock.js";
7
- export declare const isServer: boolean;
8
- export declare const isDev: boolean;
9
- export declare const hydrate: typeof hydrateCore;
10
- /**
11
- * Renders components somewhere else in the DOM
12
- *
13
- * Useful for inserting modals and tooltips outside of an cropping layout. If no mount point is given, the portal is inserted in document.body; it is wrapped in a `<div>` unless the target is document.head or `isSVG` is true. setting `useShadow` to true places the element in a shadow root to isolate styles.
14
- *
15
- * @description https://docs.solidjs.com/reference/components/portal
16
- */
17
- export declare function Portal<T extends boolean = false, S extends boolean = false>(props: {
18
- mount?: Element;
19
- children: JSX.Element;
20
- }): Text;
21
- export type DynamicProps<T extends ValidComponent, P = ComponentProps<T>> = {
22
- [K in keyof P]: P[K];
23
- } & {
24
- component: T | undefined;
25
- };
26
- /**
27
- * Renders an arbitrary component or element with the given props
28
- *
29
- * This is a lower level version of the `Dynamic` component, useful for
30
- * performance optimizations in libraries. Do not use this unless you know
31
- * what you are doing.
32
- * ```typescript
33
- * const element = () => multiline() ? 'textarea' : 'input';
34
- * createDynamic(element, { value: value() });
35
- * ```
36
- * @description https://docs.solidjs.com/reference/components/dynamic
37
- */
38
- export declare function createDynamic<T extends ValidComponent>(component: () => T | undefined, props: ComponentProps<T>): JSX.Element;
39
- /**
40
- * Renders an arbitrary custom or native component and passes the other props
41
- * ```typescript
42
- * <Dynamic component={multiline() ? 'textarea' : 'input'} value={value()} />
43
- * ```
44
- * @description https://docs.solidjs.com/reference/components/dynamic
45
- */
46
- export declare function Dynamic<T extends ValidComponent>(props: DynamicProps<T>): JSX.Element;
@@ -1,72 +0,0 @@
1
- export declare function renderToString<T>(fn: () => T, options?: {
2
- nonce?: string;
3
- renderId?: string;
4
- noScripts?: boolean;
5
- plugins?: any[];
6
- manifest?: Record<string, {
7
- file: string;
8
- css?: string[];
9
- isEntry?: boolean;
10
- isDynamicEntry?: boolean;
11
- imports?: string[];
12
- }>;
13
- onError?: (err: any) => void;
14
- }): string;
15
- export declare function renderToStringAsync<T>(fn: () => T, options?: {
16
- timeoutMs?: number;
17
- nonce?: string;
18
- renderId?: string;
19
- noScripts?: boolean;
20
- plugins?: any[];
21
- manifest?: Record<string, {
22
- file: string;
23
- css?: string[];
24
- isEntry?: boolean;
25
- isDynamicEntry?: boolean;
26
- imports?: string[];
27
- }>;
28
- onError?: (err: any) => void;
29
- }): Promise<string>;
30
- export declare function renderToStream<T>(fn: () => T, options?: {
31
- nonce?: string;
32
- renderId?: string;
33
- noScripts?: boolean;
34
- plugins?: any[];
35
- manifest?: Record<string, {
36
- file: string;
37
- css?: string[];
38
- isEntry?: boolean;
39
- isDynamicEntry?: boolean;
40
- imports?: string[];
41
- }>;
42
- onCompleteShell?: (info: {
43
- write: (v: string) => void;
44
- }) => void;
45
- onCompleteAll?: (info: {
46
- write: (v: string) => void;
47
- }) => void;
48
- onError?: (err: any) => void;
49
- }): {
50
- then: (fn: (html: string) => void) => void;
51
- pipe: (writable: {
52
- write: (v: string) => void;
53
- end: () => void;
54
- }) => void;
55
- pipeTo: (writable: WritableStream) => Promise<void>;
56
- };
57
- export declare function ssr(template: string[] | string, ...nodes: any[]): {
58
- t: string;
59
- };
60
- export declare function ssrElement(name: string, props: any, children: any, needsId: boolean): {
61
- t: string;
62
- };
63
- export declare function ssrClassList(value: {
64
- [k: string]: boolean;
65
- }): string;
66
- export declare function ssrStyle(value: {
67
- [k: string]: string;
68
- }): string;
69
- export declare function ssrAttribute(key: string, value: boolean): string;
70
- export declare function ssrHydrationKey(): string;
71
- export declare function resolveSSRNode(node: any): string;
72
- export declare function escape(html: string): string;
@@ -1,2 +0,0 @@
1
- import type { RequestEvent } from "@solidjs/web";
2
- export declare function provideRequestEvent<T extends RequestEvent, U>(init: T, cb: () => U): U;