@absolutejs/absolute 0.19.0-beta.282 → 0.19.0-beta.283

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.
@@ -0,0 +1 @@
1
+ export declare const compileVueServerModule: (sourcePath: string) => Promise<string>;
@@ -1,7 +1,11 @@
1
1
  import type { Component as SvelteComponent } from 'svelte';
2
+ export type SveltePageRenderOptions = {
3
+ bodyContent?: string;
4
+ headContent?: string;
5
+ };
2
6
  export type HandleSveltePageRequest = {
3
7
  (PageComponent: SvelteComponent<Record<string, never>>, pagePath: string, indexPath: string): Promise<Response>;
4
- <P extends Record<string, unknown>>(PageComponent: SvelteComponent<P>, pagePath: string, indexPath: string, props: NoInfer<P>): Promise<Response>;
8
+ <P extends Record<string, unknown>>(PageComponent: SvelteComponent<P>, pagePath: string, indexPath: string, props: NoInfer<P>, options?: SveltePageRenderOptions): Promise<Response>;
5
9
  };
6
10
  export declare const handleSveltePageRequest: HandleSveltePageRequest;
7
11
  export declare const invalidateSvelteSsrCache: () => void;
@@ -30144,7 +30144,7 @@ var ssrDirty = false, buildDirtyResponse = (indexPath, props) => {
30144
30144
  return new Response(html, {
30145
30145
  headers: { "Content-Type": "text/html" }
30146
30146
  });
30147
- }, handleSveltePageRequest = async (PageComponent, pagePath, indexPath, props) => {
30147
+ }, handleSveltePageRequest = async (PageComponent, pagePath, indexPath, props, options) => {
30148
30148
  if (ssrDirty) {
30149
30149
  return buildDirtyResponse(indexPath, props);
30150
30150
  }
@@ -30172,8 +30172,10 @@ var ssrDirty = false, buildDirtyResponse = (indexPath, props) => {
30172
30172
  const { renderToReadableStream: renderToReadableStream2 } = await Promise.resolve().then(() => (init_renderToReadableStream(), exports_renderToReadableStream));
30173
30173
  const ImportedPageComponent = await resolvePageComponent();
30174
30174
  const stream = await renderToReadableStream2(ImportedPageComponent, props, {
30175
+ bodyContent: options?.bodyContent,
30175
30176
  bootstrapModules: indexPath ? [indexPath] : [],
30176
- bootstrapScriptContent: `window.__INITIAL_PROPS__=${JSON.stringify(props)}`
30177
+ bootstrapScriptContent: `window.__INITIAL_PROPS__=${JSON.stringify(props)}`,
30178
+ headContent: options?.headContent
30177
30179
  });
30178
30180
  return new Response(stream, {
30179
30181
  headers: { "Content-Type": "text/html" }
@@ -30616,5 +30618,5 @@ export {
30616
30618
  createIsland
30617
30619
  };
30618
30620
 
30619
- //# debugId=A0D1E3F32E04A0C264756E2164756E21
30621
+ //# debugId=C17DF1FA47CD0EF964756E2164756E21
30620
30622
  //# sourceMappingURL=index.js.map