SSR / foldkit-ssr/vite

runtimeChunk

function · packages/ssr/src/runtimeChunk.ts:19

function runtimeChunk(options: { readonly entry: string }): Plugin

Emits entry, the module the loader's runtime imports, as a chunk of the client build, and writes that chunk's address into the loader. The chunk is the one the dynamic import loads: the bundler gives one module one chunk. A development server and a server build leave the loader without an address, and it fetches the chunk as it runs it.