foldkit-ssr 0.10.0 → 0.12.0

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 (74) hide show
  1. package/README.md +693 -61
  2. package/dist/{client-XnpTQZHw.d.ts → client-BEHlUHBv.d.ts} +10 -7
  3. package/dist/client-BEHlUHBv.d.ts.map +1 -0
  4. package/dist/client.d.ts +6 -5
  5. package/dist/client.js +66 -18
  6. package/dist/client.js.map +1 -1
  7. package/dist/context.d.ts +1 -1
  8. package/dist/context.js.map +1 -1
  9. package/dist/diagnostics.d.ts +2 -2
  10. package/dist/diagnostics.js +14 -1
  11. package/dist/diagnostics.js.map +1 -1
  12. package/dist/handoff.d.ts +23 -0
  13. package/dist/handoff.d.ts.map +1 -0
  14. package/dist/handoff.js +15 -0
  15. package/dist/handoff.js.map +1 -0
  16. package/dist/index.d.ts +108 -26
  17. package/dist/index.d.ts.map +1 -1
  18. package/dist/index.js +386 -51
  19. package/dist/index.js.map +1 -1
  20. package/dist/keep.d.ts +5 -1
  21. package/dist/keep.d.ts.map +1 -1
  22. package/dist/keep.js +55 -11
  23. package/dist/keep.js.map +1 -1
  24. package/dist/{listen-DaUPRKVR.d.ts → listen-7HzKBhqU.d.ts} +11 -2
  25. package/dist/{listen-DaUPRKVR.d.ts.map → listen-7HzKBhqU.d.ts.map} +1 -1
  26. package/dist/listen.d.ts +2 -2
  27. package/dist/listen.js +17 -7
  28. package/dist/listen.js.map +1 -1
  29. package/dist/loader.d.ts +13 -0
  30. package/dist/loader.d.ts.map +1 -0
  31. package/dist/loader.js +156 -0
  32. package/dist/loader.js.map +1 -0
  33. package/dist/marks-CX15BwOw.d.ts +39 -0
  34. package/dist/marks-CX15BwOw.d.ts.map +1 -0
  35. package/dist/marks.d.ts +2 -0
  36. package/dist/marks.js +41 -0
  37. package/dist/marks.js.map +1 -0
  38. package/dist/pageCache-DO0pOgnc.d.ts +80 -0
  39. package/dist/pageCache-DO0pOgnc.d.ts.map +1 -0
  40. package/dist/pageCache.d.ts +2 -0
  41. package/dist/pageCache.js +112 -0
  42. package/dist/pageCache.js.map +1 -0
  43. package/dist/{requestContext-D9nsbGSJ.d.ts → requestContext-DmwmQeci.d.ts} +12 -2
  44. package/dist/requestContext-DmwmQeci.d.ts.map +1 -0
  45. package/dist/requestContext.d.ts +2 -2
  46. package/dist/requestContext.js +30 -13
  47. package/dist/requestContext.js.map +1 -1
  48. package/dist/{resumable-BPN_qQHU.d.ts → resumable-BV9_OKxr.d.ts} +7 -10
  49. package/dist/resumable-BV9_OKxr.d.ts.map +1 -0
  50. package/dist/resumable.d.ts +2 -1
  51. package/dist/resumable.js +16 -19
  52. package/dist/resumable.js.map +1 -1
  53. package/dist/runtimeChunk.d.ts +13 -0
  54. package/dist/runtimeChunk.d.ts.map +1 -0
  55. package/dist/runtimeChunk.js +36 -0
  56. package/dist/runtimeChunk.js.map +1 -0
  57. package/dist/runtimeUrl.d.ts +10 -0
  58. package/dist/runtimeUrl.d.ts.map +1 -0
  59. package/dist/runtimeUrl.js +13 -0
  60. package/dist/runtimeUrl.js.map +1 -0
  61. package/dist/{shared-DbupL3vO.d.ts → shared-mQ8CXr-r.d.ts} +69 -22
  62. package/dist/shared-mQ8CXr-r.d.ts.map +1 -0
  63. package/dist/shared.d.ts +3 -2
  64. package/dist/shared.js +40 -18
  65. package/dist/shared.js.map +1 -1
  66. package/dist/vite.d.ts +3 -2
  67. package/dist/vite.d.ts.map +1 -1
  68. package/dist/vite.js +2 -1
  69. package/dist/vite.js.map +1 -1
  70. package/package.json +11 -6
  71. package/dist/client-XnpTQZHw.d.ts.map +0 -1
  72. package/dist/requestContext-D9nsbGSJ.d.ts.map +0 -1
  73. package/dist/resumable-BPN_qQHU.d.ts.map +0 -1
  74. package/dist/shared-DbupL3vO.d.ts.map +0 -1
package/dist/index.d.ts CHANGED
@@ -1,10 +1,12 @@
1
- import { n as DecodedBinding, r as EncodedBinding } from "./listen-DaUPRKVR.js";
2
- import { a as FALLBACK_FIELD, d as SLOT_ATTRIBUTE, n as BINDING_ATTRIBUTE, s as KEEP_ATTRIBUTE, u as ResumableBuilder } from "./resumable-BPN_qQHU.js";
3
- import { C as metaMarkup, E as plan, G as PageContained, J as StaticRegionMissing, K as PageFailed, M as serving, P as staticRegion, U as BundleUnloaded, W as HandlerUnnamed, c as ResumableConfig, d as ResumeRefused, f as RouteMatch, h as Start, i as Meta, j as serializeJsonScript, k as resume, l as ResumePart, n as Loadable, o as PlanSurface, p as STATIC_ATTRIBUTE, q as SsrDiagnostic, r as META_ATTRIBUTE, s as RESUME_ATTRIBUTE, t as FOLDKIT_APP_ATTRIBUTE, u as ResumePlan, z as UnnamedHandler } from "./shared-DbupL3vO.js";
4
- import { i as Resume, n as Diagnostics, o as UNTIL_LIMIT_MS, r as ReportDiagnostic, t as Diagnostic } from "./client-XnpTQZHw.js";
5
- import { n as requestContext, t as RequestContext } from "./requestContext-D9nsbGSJ.js";
1
+ import { a as UNTIL_LIMIT_MS, i as RESUME_ATTRIBUTE, n as FOLDKIT_APP_ATTRIBUTE, r as KEEP_ATTRIBUTE, t as BINDING_ATTRIBUTE } from "./marks-CX15BwOw.js";
2
+ import { n as DecodedBinding, r as EncodedBinding } from "./listen-7HzKBhqU.js";
3
+ import { c as ResumableBuilder, i as FALLBACK_FIELD, l as SLOT_ATTRIBUTE } from "./resumable-BV9_OKxr.js";
4
+ import { A as resume, D as plan, F as staticRegion, G as BundleUnloaded, J as HeadNotMoved, K as CachedPageDiffers, L as unbound, M as serializeJsonScript, N as serving, Q as StaticRegionMissing, V as UnnamedHandler, X as PageFailed, Y as PageContained, Z as SsrDiagnostic, a as Meta, d as ResumePlan, f as ResumeRefused, g as Start, i as META_ATTRIBUTE, l as ResumableConfig, m as STATIC_ATTRIBUTE, p as RouteMatch, q as HandlerUnnamed, r as Loadable, s as PlanSurface, u as ResumePart, w as metaMarkup } from "./shared-mQ8CXr-r.js";
5
+ import { i as Resume, n as Diagnostics, r as ReportDiagnostic, t as Diagnostic } from "./client-BEHlUHBv.js";
6
+ import { s as keptDocuments } from "./pageCache-DO0pOgnc.js";
7
+ import { n as requestContext, t as RequestContext } from "./requestContext-DmwmQeci.js";
6
8
  import { Cause, Effect, Layer, Option, Schema } from "effect";
7
- import { Diagnostic as Diagnostic$1, MetadataSummary } from "foldkit-surface";
9
+ import { CacheOptions, Diagnostic as Diagnostic$1, MetadataSummary, PageCacheStore } from "foldkit-surface";
8
10
  import { EntryModule, RenderError, RenderedApplication } from "foldkit/experimental/server";
9
11
  interface EnvelopeOptions {
10
12
  readonly route?: string | undefined;
@@ -21,8 +23,8 @@ interface EnvelopeOptions {
21
23
  * place the page themselves.
22
24
  */
23
25
  declare const envelope: <Model, Fields extends Schema.Struct.Fields>(resume: ResumePlan<Model, Fields>, model: Model, options?: EnvelopeOptions) => string;
24
- /** Where the browser gets a Model path's value: the envelope, the baseline, or nowhere it may. */
25
- export type Cover = 'state' | 'local' | 'missing';
26
+ /** Where the browser gets a Model path's value: the envelope, itself, or nowhere it may. */
27
+ export type Cover = 'state' | 'restored' | 'local' | 'missing';
26
28
  /** One Surface as a plan covers it, for the server's Model. */
27
29
  export interface SurfaceCoverage {
28
30
  readonly name: string;
@@ -59,11 +61,13 @@ export interface SurfaceCoverage {
59
61
  /** Whether the browser's Model activates it the same way, with the same reads. */
60
62
  readonly sameInBrowser: boolean;
61
63
  }
62
- /** What a plan sends, what it leaves local, and how it covers each Surface. */
64
+ /** What a plan sends, what it leaves local or restored, and how it covers each Surface. */
63
65
  export interface PlanInspection {
64
66
  readonly id: string;
65
67
  readonly state: ReadonlyArray<string>;
66
68
  readonly local: ReadonlyArray<string>;
69
+ /** Model paths the browser reads again before the first render. */
70
+ readonly restored: ReadonlyArray<string>;
67
71
  /** The ids of the parts that resume state the slice cannot carry. */
68
72
  readonly parts: ReadonlyArray<string>;
69
73
  readonly surfaces: ReadonlyArray<SurfaceCoverage>;
@@ -75,7 +79,7 @@ export interface PlanInspection {
75
79
  */
76
80
  declare const inspect: <Model, Fields extends Schema.Struct.Fields>(plan: ResumePlan<Model, Fields>, model: Model) => PlanInspection;
77
81
  declare const ResumeUnsafe_base: Schema.Class<ResumeUnsafe, Schema.TaggedStruct<"ResumeUnsafe", {
78
- readonly reason: Schema.Literals<readonly ["UndeclaredStartup", "Uncovered", "ViewDependsOnUnsentState", "DuplicateStaticRegion", "UngeneratablePath", "UnrestorablePart", "UnencodableBinding", "EagerStartRequired", "UndeclaredSurfaces", "BindingInStaticRegion", "VoidRootWithStyles", "UnkeepableField"]>;
82
+ readonly reason: Schema.Literals<readonly ["UndeclaredStartup", "Uncovered", "ViewDependsOnUnsentState", "DuplicateStaticRegion", "UngeneratablePath", "UnrestorablePart", "UnencodableBinding", "EagerStartRequired", "UndeclaredSurfaces", "BindingInStaticRegion", "VoidRootWithStyles", "RootRefusesHead", "UnkeepableField", "UnkeptField"]>;
79
83
  readonly message: Schema.String;
80
84
  }>, Cause.YieldableError>;
81
85
  /** Why a server refused to render a page against its plan. */
@@ -92,6 +96,8 @@ export interface RenderedPage {
92
96
  readonly envelope: string;
93
97
  /** The head markup of the plan's `meta`, empty without one. */
94
98
  readonly meta: string;
99
+ /** The compiled classes the render drew, for a stylesheet without an HTML scan. */
100
+ readonly drawn: ReadonlySet<string>;
95
101
  /**
96
102
  * Each element whose handler for an event is a function, marked `*`: the
97
103
  * page cannot answer that event before the live runtime boots.
@@ -124,12 +130,13 @@ declare const render: <Model, Fields extends Schema.Struct.Fields, Message = any
124
130
  readonly styles?: Head | undefined;
125
131
  }) => Effect.Effect<RenderedPage, RenderError | ResumeUnsafe>;
126
132
  /**
127
- * What a page adds to its head, given what it rendered: such as a stylesheet
128
- * of the classes the markup uses (`Style.usedIn` in `foldkit-mixins`). The
129
- * same shape describes `styles`, which rides in the rendered root instead,
130
- * for pages whose template the host owns.
133
+ * What a page adds to its head, given what it rendered and the compiled
134
+ * classes it drew: such as a stylesheet of those classes (`Style.usedDrawn`
135
+ * in `foldkit-mixins`, with no scan of the HTML). The same shape describes
136
+ * `styles`, which rides in the rendered root instead, for pages whose
137
+ * template the host owns.
131
138
  */
132
- export type Head = (rendered: RenderedApplication) => string;
139
+ export type Head = (rendered: RenderedApplication, drawn: ReadonlySet<string>) => string;
133
140
  /**
134
141
  * The page to serve: the rendered application in the template, with the
135
142
  * plan's `meta` and `head`'s markup, if any, before `</head>`. The envelope
@@ -139,9 +146,21 @@ export type Head = (rendered: RenderedApplication) => string;
139
146
  declare const page: (template: string, result: {
140
147
  readonly rendered: RenderedApplication;
141
148
  readonly meta: string;
149
+ readonly drawn: ReadonlySet<string>;
142
150
  }, options?: {
143
151
  readonly head?: Head | undefined;
144
152
  }) => string;
153
+ /**
154
+ * `render`, the host's document renderer, with the head markup `SSR.entry`
155
+ * carries in the rendered root (a plan's `meta`) moved before the document's
156
+ * `</head>`, where link previews and crawlers read it. Wrap whatever draws the
157
+ * document: `SSR.headed(renderDocument)`, or, for a host that hands Foldkit a
158
+ * template, `SSR.headed(application => injectIntoTemplate(template,
159
+ * application))`. The markup is taken from the rendered root alone, where the
160
+ * entry put it, so nothing a view draws elsewhere is moved. Without it the
161
+ * markup stays in the body, and `SSR.hydrate` reports `HeadNotMoved`.
162
+ */
163
+ declare const headed: <Args extends ReadonlyArray<unknown>>(render: (application: RenderedApplication, ...args: Args) => string) => (application: RenderedApplication, ...args: Args) => string;
145
164
  /** A page generated at build time, and the file a static host serves it from. */
146
165
  export interface GeneratedPage {
147
166
  readonly path: string;
@@ -221,9 +240,9 @@ declare const generate: <Model, Fields extends Schema.Struct.Fields, const Paths
221
240
  * `handleRequest` still classifies static misses and answers `HEAD` without
222
241
  * a body.
223
242
  *
224
- * What the page says of itself (`meta`) and per-page `head` markup are
225
- * written into a template's head, which the host owns here: a plan with
226
- * `meta` is refused when the entry is made, and served with `SSR.generate`.
243
+ * What the page says of itself (`meta`) belongs in the head, which the host
244
+ * owns here: the entry carries it in the rendered root, and the host's
245
+ * document renderer, wrapped in `SSR.headed`, moves it before `</head>`.
227
246
  */
228
247
  declare const entry: <Model, Fields extends Schema.Struct.Fields, Message = any>(config: ResumableConfig<Model, Message>, plan: ResumePlan<Model, Fields>, options: {
229
248
  readonly buildId: string;
@@ -284,10 +303,22 @@ declare const entry: <Model, Fields extends Schema.Struct.Fields, Message = any>
284
303
  /**
285
304
  * The status a rendered page is answered with, from the Model the server
286
305
  * reached and the request: `404` for a route the Model says is not found.
287
- * Omitted, every page is `200`. One outside `200`–`599`, or a `status`
288
- * that throws, is answered `500` and reported, as a failed render is.
306
+ * Omitted, every page is `200`. One outside `200`–`599`, a `204`, `205`
307
+ * or `304` that carries no body, or a `status` that throws, is answered
308
+ * `500` and reported, as a failed render is.
289
309
  */
290
310
  readonly status?: ((model: Model, request: Request) => number) | undefined;
311
+ /**
312
+ * Where a `GET` or `HEAD` is sent instead of drawn, from the Model
313
+ * `prepare` made: `some(path)` answers `303` to it and the page is never
314
+ * rendered, `none` renders it. The answer carries the `headers` given that
315
+ * Model, and says `cache-control: private, no-store` over any they set: a
316
+ * redirect is decided for one reader, and no cache keeps or shares it. The
317
+ * path must start with one `/` and stay on this origin
318
+ * (`/sign-in?next=%2Fnotes`); anything else, or a `redirect` that throws,
319
+ * is answered `500` and reported. A posted form is answered by `answerPost`.
320
+ */
321
+ readonly redirect?: ((model: Model, request: Request) => Option.Option<string>) | undefined;
291
322
  /**
292
323
  * How a posted form is answered. `'page'`, the default, is the page
293
324
  * `update` reached, at the address the form posted to, so a reload posts
@@ -299,11 +330,18 @@ declare const entry: <Model, Fields extends Schema.Struct.Fields, Message = any>
299
330
  readonly answerPost?: 'page' | 'redirect' | undefined;
300
331
  /**
301
332
  * The paths a build prerenders through this entry (Foldkit's plugin,
302
- * `ssr.build.prerender`), whose files a static host serves for every
303
- * query. A request for one of them with no query records its path alone,
304
- * as `SSR.generate` does, so the file resumes at `/?q=…` and the
305
- * application starts from that URL. Export the same list as the entry
306
- * module's `prerenderPaths`, which the plugin reads.
333
+ * `ssr.build.prerender`), each one file a static host serves to every
334
+ * visitor, at every query. A request for one of them with no query records
335
+ * its path alone, as `SSR.generate` does, so the file resumes at `/?q=…`
336
+ * and the application starts from that URL. Export the same list as the
337
+ * entry module's `prerenderPaths`, which the plugin reads.
338
+ *
339
+ * Such a page must be one `cache` would keep for every visitor: every
340
+ * read through `pageReader` public, no request header read (not even an
341
+ * absent one, which a file cannot vary by), nothing set by `headers`,
342
+ * and status `200`. Otherwise `renderPage` rejects naming the read, the
343
+ * header or the status, so the build fails. The page answers with no
344
+ * headers of its own, and the cache is not consulted for it.
307
345
  */
308
346
  readonly prerendered?: ReadonlyArray<string> | undefined;
309
347
  /**
@@ -313,7 +351,45 @@ declare const entry: <Model, Fields extends Schema.Struct.Fields, Message = any>
313
351
  * (`Diagnostics.Reporter`) when not given, by default the log.
314
352
  */
315
353
  readonly diagnostics?: ((diagnostic: Diagnostic$1, request: Request) => Effect.Effect<void>) | undefined;
354
+ /**
355
+ * Keeps rendered `GET` and `HEAD` pages in `store` by build and URL
356
+ * (#428). A page is kept only when every read the render made through
357
+ * `foldkit-remote-server`'s `pageReader` was public, every request
358
+ * header `flags`, `prepare`, `redirect`, `headers` or `status` read was
359
+ * absent (the request's `cookie` included), `headers` set no `cookie` or
360
+ * `cache-control` of its own, and the status is `200`: drawn from the
361
+ * URL alone. It is kept for `maxAge` or its reads' shortest, and serves
362
+ * each later request that also lacks the headers it read; it says
363
+ * `cache-control: public, max-age=…` and `vary` with those names. Every
364
+ * other page says `private, no-store`. A read made other than through
365
+ * `pageReader` is not seen, so `maxAge` is all that bounds it.
366
+ *
367
+ * The render reads a request that records its headers: one handed to
368
+ * `fetch` or `new Request` fails the render. With `check`, for
369
+ * development and tests, a kept page is drawn again for the request it
370
+ * serves, and a difference is reported (`CachedPageDiffers`) and
371
+ * answered with the page drawn again.
372
+ */
373
+ readonly cache?: PageCache | undefined;
316
374
  }) => EntryModule;
375
+ /** Where `SSR.entry` keeps pages, for how long, and whether it checks them (`cache`). */
376
+ export type PageCache = CacheOptions & {
377
+ readonly store: PageCacheStore;
378
+ readonly check?: boolean | undefined;
379
+ };
380
+ /**
381
+ * The page cache's checker, for a test: builds the entry with `make`, given a
382
+ * store in memory and `check`, and answers each request twice, so a page
383
+ * kept for one request is drawn again for every later one it serves.
384
+ * Rejects naming each page drawn otherwise for a request it served, and
385
+ * when no page was kept, which would check nothing. Give requests that
386
+ * differ in who asks (a visitor's, and one with someone's cookie); each is a
387
+ * function, since a request is read once.
388
+ */
389
+ declare const checkCache: (make: (options: {
390
+ readonly cache: PageCache;
391
+ readonly diagnostics: (diagnostic: Diagnostic$1) => Effect.Effect<void>;
392
+ }) => EntryModule, requests: ReadonlyArray<() => Request>) => Promise<void>;
317
393
  declare const FallbackRefused_base: Schema.Class<FallbackRefused, Schema.TaggedStruct<"FallbackRefused", {
318
394
  readonly reason: Schema.Literals<readonly ["Missing", "Unreadable", "Invalid", "Unlisted", "NoFallback"]>;
319
395
  readonly message: Schema.String;
@@ -336,6 +412,8 @@ interface HandleOptions<Model> {
336
412
  readonly buildId: string;
337
413
  readonly flags?: unknown;
338
414
  readonly styles?: Head | undefined;
415
+ /** Carry the plan's `meta` in the root for `SSR.headed`, as `SSR.entry` serves a post's page. */
416
+ readonly metaInRoot?: boolean | undefined;
339
417
  /** The Model the post starts from, from `init`'s, as `SSR.entry`'s `prepare`. */
340
418
  readonly prepare?: Prepare<Model> | undefined;
341
419
  /**
@@ -362,14 +440,18 @@ export declare const SSR: {
362
440
  }) => void;
363
441
  inspect: typeof inspect;
364
442
  static: typeof staticRegion;
443
+ unbound: typeof unbound;
365
444
  serving: typeof serving;
366
445
  generate: typeof generate;
367
446
  entry: typeof entry;
447
+ checkCache: typeof checkCache;
448
+ keptDocuments: typeof keptDocuments;
449
+ headed: typeof headed;
368
450
  handle: typeof handle;
369
451
  serializeJsonScript: typeof serializeJsonScript;
370
452
  sitemap: typeof sitemap;
371
453
  robots: typeof robots;
372
454
  requestContext: typeof requestContext;
373
455
  };
374
- export { BINDING_ATTRIBUTE, type BundleUnloaded, type DecodedBinding, type Diagnostic, Diagnostics, FALLBACK_FIELD, FOLDKIT_APP_ATTRIBUTE, type HandlerUnnamed, KEEP_ATTRIBUTE, type Loadable, META_ATTRIBUTE, type Meta, type PageContained, type PageFailed, type PlanSurface, RESUME_ATTRIBUTE, type ReportDiagnostic, type RequestContext, type ResumableBuilder, type ResumableConfig, Resume, type ResumePart, type ResumePlan, ResumeRefused, SLOT_ATTRIBUTE, STATIC_ATTRIBUTE, type SsrDiagnostic, type Start, type StaticRegionMissing, UNTIL_LIMIT_MS, type UnnamedHandler, metaMarkup };
456
+ export { BINDING_ATTRIBUTE, type BundleUnloaded, type CachedPageDiffers, type DecodedBinding, type Diagnostic, Diagnostics, FALLBACK_FIELD, FOLDKIT_APP_ATTRIBUTE, type HandlerUnnamed, type HeadNotMoved, KEEP_ATTRIBUTE, type Loadable, META_ATTRIBUTE, type Meta, type PageContained, type PageFailed, type PlanSurface, RESUME_ATTRIBUTE, type ReportDiagnostic, type RequestContext, type ResumableBuilder, type ResumableConfig, Resume, type ResumePart, type ResumePlan, ResumeRefused, SLOT_ATTRIBUTE, STATIC_ATTRIBUTE, type SsrDiagnostic, type Start, type StaticRegionMissing, UNTIL_LIMIT_MS, type UnnamedHandler, metaMarkup };
375
457
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","names":["Diagnostic"],"sources":["../src/index.ts"],"mappings":";;;;;;;;UAgGU;WACC;WACA,QAAQ;WACR,WAAW,cAAc;;WAEzB,SAAS;;;;;;;;;cAUd,WAAY,OAAO,eAAe,OAAO,OAAO,QAAM,QAClD,WAAW,OAAO,SAAO,OAC1B,OAAK,UACH;;YAgHC;;iBAGK;WACN;;WAEA;;WAEA;;;;;WAKA;aAEM;aACA;eAAwB;eAAuB,OAAO;;;;WAI5D;aAAwB;aAAuB,OAAO;;;WAEtD,OAAO;aAAyB;aAAuB,OAAO;;;;;;WAK9D,WAAW,cA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