UNPKG

@analogjs/platform

Version:

The fullstack meta-framework for Angular

16 lines (15 loc) 761 B
import { type Plugin } from 'vite'; export declare function ssrBuildPlugin(): Plugin; /** * Vite plugin that patches `@angular/core`'s `getComponentId()` to * mirror every compiled component definition to a global Set, bypassing * the `ngServerMode` guard that normally prevents registration on the * server. The set lives at `globalThis.__ngComponentDefs` and is read by * `@analogjs/router`'s SSR render function to null cached `tView` * objects between requests so that `$localize` tagged templates in * `consts()` re-evaluate with the freshly loaded translations. * * Only active when the platform's `i18n` option is configured. * Only transforms `@angular/core` modules in SSR builds. */ export declare function i18nDefRegistryPlugin(): Plugin;