@jay-framework/stack-server-runtime 0.13.0 → 0.15.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 (3) hide show
  1. package/dist/index.d.ts +157 -106
  2. package/dist/index.js +752 -366
  3. package/package.json +13 -12
package/dist/index.d.ts CHANGED
@@ -4,11 +4,11 @@ import { ViteDevServer } from 'vite';
4
4
  import { JayRoute } from '@jay-framework/stack-route-scanner';
5
5
  import { WithValidations, JsonSchemaProperty, PluginManifest } from '@jay-framework/compiler-shared';
6
6
  export { JsonSchemaProperty } from '@jay-framework/compiler-shared';
7
- import { Contract, HeadlessContractInfo, ForEachHeadlessInstance, DiscoveredHeadlessInstance } from '@jay-framework/compiler-jay-html';
7
+ import { Contract, HeadlessContractInfo, DiscoveredHeadlessInstance, ForEachHeadlessInstance } from '@jay-framework/compiler-jay-html';
8
8
  export { ForEachHeadlessInstance } from '@jay-framework/compiler-jay-html';
9
9
  import { JayRollupConfig } from '@jay-framework/rollup-plugin';
10
- import { TrackByMap } from '@jay-framework/view-state-merge';
11
10
  import { Coordinate } from '@jay-framework/runtime';
11
+ import { TrackByMap } from '@jay-framework/view-state-merge';
12
12
 
13
13
  interface DevServerPagePart {
14
14
  compDefinition: AnyJayStackComponentDefinition;
@@ -45,6 +45,10 @@ interface LoadedPageParts {
45
45
  headlessContracts: HeadlessContractInfo[];
46
46
  /** Instance-only headless components (no key) for server-side phase orchestration */
47
47
  headlessInstanceComponents: HeadlessInstanceComponent[];
48
+ /** Discovered <jay:xxx> instances from the jay-html (DL#109) */
49
+ discoveredInstances: DiscoveredHeadlessInstance[];
50
+ /** Discovered forEach <jay:xxx> instances from the jay-html (DL#109) */
51
+ forEachInstances: ForEachHeadlessInstance[];
48
52
  }
49
53
  interface LoadPagePartsOptions {
50
54
  /**
@@ -53,21 +57,81 @@ interface LoadPagePartsOptions {
53
57
  * Import resolution still uses the original jay-html's directory.
54
58
  */
55
59
  preRenderedPath?: string;
60
+ /**
61
+ * Pre-loaded jay-html content to use instead of reading from disk.
62
+ * When provided (e.g., from SlowRenderCache with cache tag already stripped),
63
+ * this content is used directly, avoiding an extra file read.
64
+ */
65
+ preRenderedContent?: string;
56
66
  }
57
67
  declare function loadPageParts(vite: ViteDevServer, route: JayRoute, pagesBase: string, projectBase: string, jayRollupConfig: JayRollupConfig, options?: LoadPagePartsOptions): Promise<WithValidations<LoadedPageParts>>;
58
68
 
59
69
  interface SlowlyChangingPhase {
60
- runSlowlyForPage(pageParams: object, pageProps: PageProps, parts: Array<DevServerPagePart>): Promise<AnySlowlyRenderResult>;
70
+ runSlowlyForPage(pageParams: object, pageProps: PageProps, parts: Array<DevServerPagePart>, discoveredInstances?: DiscoveredHeadlessInstance[], headlessInstanceComponents?: HeadlessInstanceComponent[], jayHtmlPath?: string): Promise<AnySlowlyRenderResult>;
61
71
  }
62
72
  declare class DevSlowlyChangingPhase implements SlowlyChangingPhase {
63
- private dontCacheSlowly;
64
- constructor(dontCacheSlowly: boolean);
65
- runSlowlyForPage(pageParams: UrlParams, pageProps: PageProps, parts: Array<DevServerPagePart>): Promise<AnySlowlyRenderResult>;
73
+ runSlowlyForPage(pageParams: UrlParams, pageProps: PageProps, parts: Array<DevServerPagePart>, discoveredInstances?: DiscoveredHeadlessInstance[], headlessInstanceComponents?: HeadlessInstanceComponent[], jayHtmlPath?: string): Promise<AnySlowlyRenderResult>;
66
74
  }
67
75
  declare function runLoadParams<Refs extends object, SlowVS extends object, FastVS extends object, InteractiveVS extends object, Services extends Array<any>, Contexts extends Array<any>, PropsT extends object, Params extends UrlParams, CompCore extends JayComponentCore<PropsT, InteractiveVS>>(compDefinition: JayStackComponentDefinition<Refs, SlowVS, FastVS, InteractiveVS, Services, Contexts, PropsT, Params, CompCore>, services: Services): Promise<void>;
68
76
  declare function runSlowlyChangingRender<Refs extends object, SlowVS extends object, FastVS extends object, InteractiveVS extends object, Services extends Array<any>, Contexts extends Array<any>, PropsT extends object, Params extends UrlParams, CompCore extends JayComponentCore<PropsT, InteractiveVS>>(compDefinition: JayStackComponentDefinition<Refs, SlowVS, FastVS, InteractiveVS, Services, Contexts, PropsT, Params, CompCore>): void;
69
77
 
70
- declare function renderFastChangingData(pageParams: object, pageProps: PageProps, carryForward: object, parts: Array<DevServerPagePart>): Promise<AnyFastRenderResult>;
78
+ /**
79
+ * Server-side slow render orchestration for headless component instances.
80
+ *
81
+ * Given discovered instances (from discoverHeadlessInstances) and their
82
+ * component definitions, runs slowlyRender for each instance and collects
83
+ * the results for downstream consumers (pre-render pipeline, direct mode, fast phase).
84
+ */
85
+
86
+ /**
87
+ * Data needed by the fast phase to render headless instances.
88
+ * Stored in carryForward.__instances so the fast phase can access it
89
+ * (both in pre-render and cached flows).
90
+ */
91
+ interface InstancePhaseData {
92
+ /** Discovered instances with their props and coordinates */
93
+ discovered: Array<{
94
+ contractName: string;
95
+ props: Record<string, string>;
96
+ coordinate: Coordinate;
97
+ }>;
98
+ /** CarryForward per instance (keyed by coordinate path, e.g. "p1/product-card:0") */
99
+ carryForwards: Record<string, object>;
100
+ /** ForEach instances that need fast-phase per-item rendering */
101
+ forEachInstances?: ForEachHeadlessInstance[];
102
+ }
103
+ /**
104
+ * Result of running slowlyRender for all discovered headless instances.
105
+ */
106
+ interface InstanceSlowRenderResult {
107
+ /** Resolved data for each instance (for resolveHeadlessInstances pass 2) */
108
+ resolvedData: Array<{
109
+ coordinate: Coordinate;
110
+ contract: Contract;
111
+ slowViewState: Record<string, unknown>;
112
+ }>;
113
+ /** Per-instance slow ViewState keyed by coordinate (for direct mode merge) */
114
+ slowViewStates: Record<string, object>;
115
+ /** Phase data for the fast render phase */
116
+ instancePhaseData: InstancePhaseData;
117
+ }
118
+ /**
119
+ * Run slowlyRender for each discovered headless instance.
120
+ *
121
+ * Shared between preRenderJayHtml (pre-render path) and handleDirectRequest (direct path).
122
+ */
123
+ declare function slowRenderInstances(discovered: DiscoveredHeadlessInstance[], headlessInstanceComponents: HeadlessInstanceComponent[]): Promise<InstanceSlowRenderResult | undefined>;
124
+ /**
125
+ * Validate that forEach headless instances do not have a slow phase.
126
+ *
127
+ * Components with slowlyRender cannot be used inside forEach because
128
+ * forEach items are only known at request time, after slow rendering completes.
129
+ *
130
+ * @returns Array of validation error messages (empty if all valid)
131
+ */
132
+ declare function validateForEachInstances(forEachInstances: ForEachHeadlessInstance[], headlessInstanceComponents: HeadlessInstanceComponent[]): string[];
133
+
134
+ declare function renderFastChangingData(pageParams: object, pageProps: PageProps, carryForward: object, parts: Array<DevServerPagePart>, instancePhaseData?: InstancePhaseData, forEachInstances?: ForEachHeadlessInstance[], headlessInstanceComponents?: HeadlessInstanceComponent[], mergedSlowViewState?: object): Promise<AnyFastRenderResult>;
71
135
 
72
136
  /**
73
137
  * Action metadata loaded from .jay-action files.
@@ -497,8 +561,50 @@ interface GenerateClientScriptOptions {
497
561
  */
498
562
  slowViewState?: object;
499
563
  }
564
+ /**
565
+ * Shared fragments generated by buildScriptFragments().
566
+ * Used by both generateClientScript() and generateHydrationScript().
567
+ */
568
+ interface ScriptFragments {
569
+ partImports: string;
570
+ compositeParts: string;
571
+ pluginClientInitImports: string;
572
+ projectInitImport: string;
573
+ clientInitExecution: string;
574
+ automationImport: string;
575
+ slowViewStateDecl: string;
576
+ }
577
+ /**
578
+ * Build the shared script fragments used by both client and hydration scripts.
579
+ */
580
+ declare function buildScriptFragments(parts: DevServerPagePart[], clientInitData: Record<string, Record<string, any>>, projectInit: ProjectClientInitInfo | undefined, pluginInits: PluginClientInitInfo[], options: GenerateClientScriptOptions): ScriptFragments;
581
+ /**
582
+ * Generate the automation wrapping code.
583
+ * @param mode - 'client' appends to DOM; 'hydrate' skips appendChild (DOM already present)
584
+ */
585
+ declare function buildAutomationWrap(options: GenerateClientScriptOptions, mode: 'client' | 'hydrate'): string;
500
586
  declare function generateClientScript(defaultViewState: object, fastCarryForward: object, parts: DevServerPagePart[], jayHtmlPath: string, trackByMap?: TrackByMap, clientInitData?: Record<string, Record<string, any>>, projectInit?: ProjectClientInitInfo, pluginInits?: PluginClientInitInfo[], options?: GenerateClientScriptOptions): string;
501
587
 
588
+ /**
589
+ * Invalidate the cached server element module for a jay-html file.
590
+ * Called when the source file changes (via file watcher).
591
+ */
592
+ declare function invalidateServerElementCache(jayHtmlPath: string): void;
593
+ /**
594
+ * Invalidate all cached server element modules.
595
+ */
596
+ declare function clearServerElementCache(): void;
597
+ /**
598
+ * Generate a complete SSR HTML page with server-rendered content and hydration script.
599
+ *
600
+ * Flow:
601
+ * 1. Load (or reuse cached) server element module
602
+ * 2. Execute renderToStream() to produce HTML
603
+ * 3. Build hydration script (uses ?jay-hydrate query for hydrate target)
604
+ * 4. Return full HTML page string
605
+ */
606
+ declare function generateSSRPageHtml(vite: ViteDevServer, jayHtmlContent: string, jayHtmlFilename: string, jayHtmlDir: string, viewState: object, jayHtmlImportPath: string, parts: DevServerPagePart[], carryForward: object, trackByMap: TrackByMap, clientInitData: Record<string, Record<string, any>>, buildFolder: string, projectRoot: string, routeDir: string, tsConfigFilePath?: string, projectInit?: ProjectClientInitInfo, pluginInits?: PluginClientInitInfo[], options?: GenerateClientScriptOptions): Promise<string>;
607
+
502
608
  /**
503
609
  * Service registry for Jay Stack server-side dependency injection.
504
610
  *
@@ -668,90 +774,35 @@ declare function getClientInitDataForKey(key: string): Record<string, any>;
668
774
  */
669
775
  declare function clearClientInitData(): void;
670
776
 
671
- /**
672
- * Server-side slow render orchestration for headless component instances.
673
- *
674
- * Given discovered instances (from discoverHeadlessInstances) and their
675
- * component definitions, runs slowlyRender for each instance and collects
676
- * the results for downstream consumers (pre-render pipeline, direct mode, fast phase).
677
- */
678
-
679
- /**
680
- * Data needed by the fast phase to render headless instances.
681
- * Stored in carryForward.__instances so the fast phase can access it
682
- * (both in pre-render and cached flows).
683
- */
684
- interface InstancePhaseData {
685
- /** Discovered instances with their props and coordinates */
686
- discovered: Array<{
687
- contractName: string;
688
- props: Record<string, string>;
689
- coordinate: Coordinate;
690
- }>;
691
- /** CarryForward per instance (keyed by coordinate path, e.g. "p1/product-card:0") */
692
- carryForwards: Record<string, object>;
693
- /** ForEach instances that need fast-phase per-item rendering */
694
- forEachInstances?: ForEachHeadlessInstance[];
695
- }
696
- /**
697
- * Result of running slowlyRender for all discovered headless instances.
698
- */
699
- interface InstanceSlowRenderResult {
700
- /** Resolved data for each instance (for resolveHeadlessInstances pass 2) */
701
- resolvedData: Array<{
702
- coordinate: Coordinate;
703
- contract: Contract;
704
- slowViewState: Record<string, unknown>;
705
- }>;
706
- /** Per-instance slow ViewState keyed by coordinate (for direct mode merge) */
707
- slowViewStates: Record<string, object>;
708
- /** Phase data for the fast render phase */
709
- instancePhaseData: InstancePhaseData;
710
- }
711
- /**
712
- * Run slowlyRender for each discovered headless instance.
713
- *
714
- * Shared between preRenderJayHtml (pre-render path) and handleDirectRequest (direct path).
715
- */
716
- declare function slowRenderInstances(discovered: DiscoveredHeadlessInstance[], headlessInstanceComponents: HeadlessInstanceComponent[]): Promise<InstanceSlowRenderResult | undefined>;
717
- /**
718
- * Validate that forEach headless instances do not have a slow phase.
719
- *
720
- * Components with slowlyRender cannot be used inside forEach because
721
- * forEach items are only known at request time, after slow rendering completes.
722
- *
723
- * @returns Array of validation error messages (empty if all valid)
724
- */
725
- declare function validateForEachInstances(forEachInstances: ForEachHeadlessInstance[], headlessInstanceComponents: HeadlessInstanceComponent[]): string[];
726
-
727
777
  /**
728
778
  * Cache entry for pre-rendered jay-html
729
779
  */
730
780
  interface SlowRenderCacheEntry {
731
781
  /** Path to the pre-rendered jay-html file on disk */
732
782
  preRenderedPath: string;
783
+ /** Pre-rendered jay-html content with cache metadata tag stripped */
784
+ preRenderedContent: string;
733
785
  /** Slow ViewState that was baked into the jay-html */
734
786
  slowViewState: object;
735
787
  /** CarryForward data from slow rendering (passed to fast phase) */
736
788
  carryForward: object;
737
- /** Timestamp when this entry was created */
738
- createdAt: number;
739
789
  /** Source jay-html path (for debugging) */
740
790
  sourcePath: string;
741
791
  }
742
792
  /**
743
- * Cache for pre-rendered jay-html files.
793
+ * Filesystem-based cache for pre-rendered jay-html files.
744
794
  *
745
- * This cache stores jay-html content that has been transformed with slow-phase
746
- * data baked in. The key insight is that since slow ViewState is embedded directly
747
- * into the jay-html, we don't need to pass it to the client - only fast and
748
- * interactive ViewState is sent.
795
+ * Cache metadata (slowViewState, carryForward) is embedded in the pre-rendered
796
+ * file as a `<script type="application/jay-cache">` tag. This means:
797
+ * - Cache survives dev server restart
798
+ * - The filesystem is the single source of truth
799
+ * - No in-memory map needed for cache entries
749
800
  *
750
- * Pre-rendered files are written to disk so Vite can pick them up and compile them.
801
+ * On read, the script tag is extracted and stripped before returning content.
751
802
  */
752
803
  declare class SlowRenderCache {
753
- private cache;
754
- private pathToKeys;
804
+ /** Maps source jay-html path → set of pre-rendered file paths (for invalidation) */
805
+ private pathToFiles;
755
806
  private readonly cacheDir;
756
807
  private readonly pagesRoot;
757
808
  /**
@@ -760,22 +811,23 @@ declare class SlowRenderCache {
760
811
  */
761
812
  constructor(cacheDir: string, pagesRoot: string);
762
813
  /**
763
- * Get a cached pre-rendered jay-html entry
814
+ * Get a cached pre-rendered jay-html entry by reading from disk.
815
+ * Returns undefined if the cache file doesn't exist or has no metadata tag.
764
816
  */
765
- get(jayHtmlPath: string, params: Record<string, string>): SlowRenderCacheEntry | undefined;
817
+ get(jayHtmlPath: string, params: Record<string, string>): Promise<SlowRenderCacheEntry | undefined>;
766
818
  /**
767
- * Store a pre-rendered jay-html entry in the cache.
768
- * Writes the pre-rendered content to disk and stores metadata in memory.
819
+ * Store a pre-rendered jay-html entry.
820
+ * Embeds metadata as a <script> tag and writes to disk.
821
+ * Returns the full cache entry with stripped content.
769
822
  */
770
- set(jayHtmlPath: string, params: Record<string, string>, preRenderedJayHtml: string, slowViewState: object, carryForward: object): Promise<string>;
823
+ set(jayHtmlPath: string, params: Record<string, string>, preRenderedJayHtml: string, slowViewState: object, carryForward: object): Promise<SlowRenderCacheEntry>;
771
824
  /**
772
825
  * Check if a pre-rendered entry exists for the given path and params
773
826
  */
774
- has(jayHtmlPath: string, params: Record<string, string>): boolean;
827
+ has(jayHtmlPath: string, params: Record<string, string>): Promise<boolean>;
775
828
  /**
776
829
  * Invalidate all cached entries for a given jay-html source path.
777
- * This is called when the source file changes.
778
- * Also deletes the cached files from disk.
830
+ * Deletes cached files from disk.
779
831
  */
780
832
  invalidate(jayHtmlPath: string): Promise<void>;
781
833
  /**
@@ -793,14 +845,23 @@ declare class SlowRenderCache {
793
845
  * Clear all cached entries and delete cached files from disk
794
846
  */
795
847
  clear(): Promise<void>;
796
- /**
797
- * Get the number of cached entries
798
- */
799
- get size(): number;
800
848
  /**
801
849
  * Get all cached jay-html paths (for debugging/monitoring)
802
850
  */
803
851
  getCachedPaths(): string[];
852
+ /**
853
+ * Compute the cache file path for a given jay-html path and params.
854
+ */
855
+ private computeCachePath;
856
+ /**
857
+ * Track a pre-rendered file path for invalidation.
858
+ */
859
+ private trackFile;
860
+ /**
861
+ * Scan the cache directory for files matching a route and delete them.
862
+ * Handles the startup case where pathToFiles is not populated from a previous session.
863
+ */
864
+ private scanAndDeleteCacheFiles;
804
865
  }
805
866
 
806
867
  /**
@@ -812,18 +873,6 @@ declare class SlowRenderCache {
812
873
  * @see Design Log #80 - Materializing Dynamic Contracts for Agentic Page Generation
813
874
  */
814
875
 
815
- interface ContractIndexEntry {
816
- plugin: string;
817
- name: string;
818
- type: 'static' | 'dynamic';
819
- path: string;
820
- metadata?: Record<string, unknown>;
821
- }
822
- interface ContractsIndex {
823
- materialized_at: string;
824
- jay_stack_version: string;
825
- contracts: ContractIndexEntry[];
826
- }
827
876
  /** Action metadata entry in plugins-index.yaml */
828
877
  interface ActionIndexEntry {
829
878
  name: string;
@@ -831,20 +880,22 @@ interface ActionIndexEntry {
831
880
  /** Path to the .jay-action file (relative to project root) */
832
881
  path: string;
833
882
  }
883
+ /** Contract entry within a plugin in plugins-index.yaml */
884
+ interface PluginContractEntry {
885
+ name: string;
886
+ type: 'static' | 'dynamic';
887
+ path: string;
888
+ metadata?: Record<string, unknown>;
889
+ }
834
890
  /** Entry for plugins-index.yaml (Design Log #85) */
835
891
  interface PluginsIndexEntry {
836
892
  name: string;
837
893
  path: string;
838
- contracts: Array<{
839
- name: string;
840
- type: 'static' | 'dynamic';
841
- path: string;
842
- }>;
894
+ contracts: PluginContractEntry[];
843
895
  /** Actions with .jay-action metadata (exposed to AI agents) */
844
896
  actions?: ActionIndexEntry[];
845
897
  }
846
898
  interface PluginsIndex {
847
- materialized_at: string;
848
899
  jay_stack_version: string;
849
900
  plugins: PluginsIndexEntry[];
850
901
  }
@@ -859,7 +910,7 @@ interface MaterializeContractsOptions {
859
910
  viteServer?: ViteSSRLoader;
860
911
  }
861
912
  interface MaterializeResult {
862
- index: ContractsIndex;
913
+ pluginsIndex: PluginsIndex;
863
914
  staticCount: number;
864
915
  dynamicCount: number;
865
916
  outputDir: string;
@@ -874,7 +925,7 @@ declare function materializeContracts(options: MaterializeContractsOptions, serv
874
925
  /**
875
926
  * Lists contracts without writing files (for --list mode)
876
927
  */
877
- declare function listContracts(options: MaterializeContractsOptions): Promise<ContractsIndex>;
928
+ declare function listContracts(options: MaterializeContractsOptions): Promise<PluginsIndex>;
878
929
 
879
930
  /**
880
931
  * Plugin Scanner
@@ -1077,4 +1128,4 @@ declare function executePluginReferences(plugin: PluginWithReferences, options:
1077
1128
  verbose?: boolean;
1078
1129
  }): Promise<PluginReferencesResult>;
1079
1130
 
1080
- export { type ActionDiscoveryOptions, type ActionDiscoveryResult, type ActionErrorResponse, type ActionExecutionResult, type ActionIndexEntry, type ActionMetadata, ActionRegistry, type ActionSchema, type ContractIndexEntry, type ContractsIndex, type DevServerPagePart, DevSlowlyChangingPhase, type GenerateClientScriptOptions, type HeadlessInstanceComponent, type InstancePhaseData, type InstanceSlowRenderResult, type LoadedPageParts, type MaterializeContractsOptions, type MaterializeResult, type PluginActionDiscoveryOptions, type PluginClientInitInfo, type PluginInitDiscoveryOptions, type PluginReferencesContext, type PluginReferencesHandler, type PluginReferencesResult, type PluginScanOptions, type PluginSetupContext, type PluginSetupHandler, type PluginSetupResult, type PluginWithInit, type PluginWithReferences, type PluginWithSetup, type PluginsIndex, type PluginsIndexEntry, type ProjectClientInitInfo, type RegisteredAction, type ScannedPlugin, SlowRenderCache, type SlowRenderCacheEntry, type SlowlyChangingPhase, type ViteSSRLoader, actionRegistry, clearActionRegistry, clearClientInitData, clearLifecycleCallbacks, clearServiceRegistry, discoverAllPluginActions, discoverAndRegisterActions, discoverPluginActions, discoverPluginsWithInit, discoverPluginsWithReferences, discoverPluginsWithSetup, executeAction, executePluginReferences, executePluginServerInits, executePluginSetup, generateClientScript, getActionCacheHeaders, getClientInitData, getClientInitDataForKey, getRegisteredAction, getRegisteredActionNames, getService, getServiceRegistry, hasAction, hasService, listContracts, loadActionMetadata, loadPageParts, materializeContracts, onInit, onShutdown, parseActionMetadata, preparePluginClientInits, registerAction, registerService, renderFastChangingData, resolveActionMetadataPath, resolveServices, runInitCallbacks, runLoadParams, runShutdownCallbacks, runSlowlyChangingRender, scanPlugins, setClientInitData, slowRenderInstances, sortPluginsByDependencies, validateForEachInstances };
1131
+ export { type ActionDiscoveryOptions, type ActionDiscoveryResult, type ActionErrorResponse, type ActionExecutionResult, type ActionIndexEntry, type ActionMetadata, ActionRegistry, type ActionSchema, type DevServerPagePart, DevSlowlyChangingPhase, type GenerateClientScriptOptions, type HeadlessInstanceComponent, type InstancePhaseData, type InstanceSlowRenderResult, type LoadedPageParts, type MaterializeContractsOptions, type MaterializeResult, type PluginActionDiscoveryOptions, type PluginClientInitInfo, type PluginContractEntry, type PluginInitDiscoveryOptions, type PluginReferencesContext, type PluginReferencesHandler, type PluginReferencesResult, type PluginScanOptions, type PluginSetupContext, type PluginSetupHandler, type PluginSetupResult, type PluginWithInit, type PluginWithReferences, type PluginWithSetup, type PluginsIndex, type PluginsIndexEntry, type ProjectClientInitInfo, type RegisteredAction, type ScannedPlugin, type ScriptFragments, SlowRenderCache, type SlowRenderCacheEntry, type SlowlyChangingPhase, type ViteSSRLoader, actionRegistry, buildAutomationWrap, buildScriptFragments, clearActionRegistry, clearClientInitData, clearLifecycleCallbacks, clearServerElementCache, clearServiceRegistry, discoverAllPluginActions, discoverAndRegisterActions, discoverPluginActions, discoverPluginsWithInit, discoverPluginsWithReferences, discoverPluginsWithSetup, executeAction, executePluginReferences, executePluginServerInits, executePluginSetup, generateClientScript, generateSSRPageHtml, getActionCacheHeaders, getClientInitData, getClientInitDataForKey, getRegisteredAction, getRegisteredActionNames, getService, getServiceRegistry, hasAction, hasService, invalidateServerElementCache, listContracts, loadActionMetadata, loadPageParts, materializeContracts, onInit, onShutdown, parseActionMetadata, preparePluginClientInits, registerAction, registerService, renderFastChangingData, resolveActionMetadataPath, resolveServices, runInitCallbacks, runLoadParams, runShutdownCallbacks, runSlowlyChangingRender, scanPlugins, setClientInitData, slowRenderInstances, sortPluginsByDependencies, validateForEachInstances };