Open History to see the last commit
1/**
2 * WHAT IS THIS FILE?
3 *
4 * SSR entry point, in all cases the application is rendered outside the browser, this
5 * entry point will be the common one.
6 *
7 * - Server (express, cloudflare...)
8 * - npm run start
9 * - npm run preview
10 * - npm run build
11 *
12 */
13import {
14 renderToStream,
15 type RenderToStreamOptions,
16} from "@builder.io/qwik/server";
17import { manifest } from "@qwik-client-manifest";
18import Root from "./root";
19
20export default function (opts: RenderToStreamOptions) {
21 return renderToStream(<Root />, {
22 manifest,
23 ...opts,
24 // Use container attributes to set attributes on the html tag.
25 containerAttributes: {
26 lang: "en-us",
27 ...opts.containerAttributes,
28 },
29 serverData: {
30 ...opts.serverData,
31 },
32 });
33}