@ecopages/core 0.2.0-beta.1 → 0.2.0-beta.10

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 (216) hide show
  1. package/package.json +107 -3
  2. package/src/adapters/abstract/application-adapter.d.ts +73 -1
  3. package/src/adapters/abstract/application-adapter.js +89 -0
  4. package/src/adapters/abstract/server-adapter.d.ts +3 -0
  5. package/src/adapters/abstract/ws-pattern-matcher.d.ts +60 -0
  6. package/src/adapters/abstract/ws-pattern-matcher.js +61 -0
  7. package/src/adapters/bun/client-bridge.d.ts +1 -0
  8. package/src/adapters/bun/client-bridge.js +3 -0
  9. package/src/adapters/bun/create-app.d.ts +5 -3
  10. package/src/adapters/bun/create-app.js +44 -39
  11. package/src/adapters/bun/hmr-manager.d.ts +2 -1
  12. package/src/adapters/bun/hmr-manager.js +2 -2
  13. package/src/adapters/bun/server-adapter.d.ts +81 -20
  14. package/src/adapters/bun/server-adapter.js +220 -78
  15. package/src/adapters/bun/static-preview-host.js +25 -20
  16. package/src/adapters/create-app.d.ts +13 -0
  17. package/src/adapters/create-app.js +10 -1
  18. package/src/adapters/node/create-app.d.ts +4 -0
  19. package/src/adapters/node/create-app.js +38 -9
  20. package/src/adapters/node/node-client-bridge.d.ts +1 -0
  21. package/src/adapters/node/node-client-bridge.js +3 -0
  22. package/src/adapters/node/node-hmr-manager.d.ts +2 -1
  23. package/src/adapters/node/node-hmr-manager.js +2 -2
  24. package/src/adapters/node/server-adapter-dependencies.js +2 -0
  25. package/src/adapters/node/server-adapter.d.ts +55 -19
  26. package/src/adapters/node/server-adapter.js +140 -132
  27. package/src/adapters/node/static-content-server.d.ts +1 -0
  28. package/src/adapters/node/static-content-server.js +10 -2
  29. package/src/adapters/node/static-preview-host.js +27 -12
  30. package/src/adapters/shared/bun-user-websocket-lifecycle.d.ts +22 -0
  31. package/src/adapters/shared/bun-user-websocket-lifecycle.js +96 -0
  32. package/src/adapters/shared/copy-runtime-public-dir.d.ts +6 -0
  33. package/src/adapters/shared/copy-runtime-public-dir.js +24 -0
  34. package/src/adapters/shared/hmr-html-response.d.ts +1 -1
  35. package/src/adapters/shared/hmr-html-response.js +4 -1
  36. package/src/adapters/shared/node-http-websocket-upgrades.d.ts +21 -0
  37. package/src/adapters/shared/node-http-websocket-upgrades.js +100 -0
  38. package/src/adapters/shared/port-manager.d.ts +116 -0
  39. package/src/adapters/shared/port-manager.js +196 -0
  40. package/src/adapters/shared/runtime-app-bootstrap.d.ts +2 -1
  41. package/src/adapters/shared/runtime-app-bootstrap.js +3 -6
  42. package/src/adapters/shared/runtime-server-lifecycle.d.ts +38 -0
  43. package/src/adapters/shared/runtime-server-lifecycle.js +39 -0
  44. package/src/adapters/shared/server-adapter.d.ts +2 -1
  45. package/src/adapters/shared/server-adapter.js +12 -4
  46. package/src/adapters/shared/server-route-handler.d.ts +4 -1
  47. package/src/adapters/shared/server-route-handler.js +5 -2
  48. package/src/adapters/shared/server-static-builder.d.ts +14 -29
  49. package/src/adapters/shared/server-static-builder.js +91 -70
  50. package/src/adapters/shared/shared-hmr-manager.d.ts +12 -0
  51. package/src/adapters/shared/shared-hmr-manager.js +64 -7
  52. package/src/adapters/shared/static-preview-host.d.ts +5 -0
  53. package/src/adapters/shared/websocket-lifecycle.d.ts +24 -0
  54. package/src/adapters/shared/websocket-lifecycle.js +55 -0
  55. package/src/build/README.md +77 -14
  56. package/src/build/app-build-manifest-runtime.d.ts +10 -0
  57. package/src/build/app-build-manifest-runtime.js +90 -0
  58. package/src/build/build-adapter.d.ts +17 -319
  59. package/src/build/build-adapter.js +28 -94
  60. package/src/build/build-contracts.d.ts +97 -0
  61. package/src/build/build-contracts.js +0 -0
  62. package/src/build/build-input-fingerprint.d.ts +28 -0
  63. package/src/build/build-input-fingerprint.js +31 -0
  64. package/src/build/build-profile-options.d.ts +7 -0
  65. package/src/build/build-profile-options.js +37 -0
  66. package/src/build/build-runtime.d.ts +24 -0
  67. package/src/build/build-runtime.js +65 -0
  68. package/src/build/deduping-build-executor.d.ts +28 -0
  69. package/src/build/deduping-build-executor.js +56 -0
  70. package/src/build/jsx-ownership-plugins.d.ts +24 -0
  71. package/src/build/jsx-ownership-plugins.js +41 -0
  72. package/src/build/pages-unified-graph-build.d.ts +31 -0
  73. package/src/build/pages-unified-graph-build.js +206 -0
  74. package/src/build/parallel-build-executor.d.ts +21 -0
  75. package/src/build/parallel-build-executor.js +52 -0
  76. package/src/build/production-build-cache.d.ts +20 -0
  77. package/src/build/production-build-cache.js +63 -0
  78. package/src/build/rolldown-adapter-helpers.d.ts +3 -6
  79. package/src/build/rolldown-adapter-helpers.js +71 -6
  80. package/src/build/rolldown-build-adapter.d.ts +2 -6
  81. package/src/build/rolldown-build-adapter.js +3 -3
  82. package/src/build/rolldown-build-invocation-metrics.d.ts +12 -0
  83. package/src/build/rolldown-build-invocation-metrics.js +43 -0
  84. package/src/build/rolldown-plugin-bridge.d.ts +15 -1
  85. package/src/build/rolldown-plugin-bridge.js +20 -5
  86. package/src/build/rolldown-source-transform-pass.d.ts +15 -0
  87. package/src/build/rolldown-source-transform-pass.js +58 -0
  88. package/src/build/runtime-build-executor.d.ts +8 -15
  89. package/src/build/runtime-build-executor.js +12 -15
  90. package/src/build/runtime-build-output-normalizer.d.ts +7 -0
  91. package/src/build/runtime-build-output-normalizer.js +94 -2
  92. package/src/build/server-entry-build-cache.d.ts +44 -0
  93. package/src/build/server-entry-build-cache.js +161 -0
  94. package/src/config/config-builder.d.ts +12 -7
  95. package/src/config/config-builder.js +12 -9
  96. package/src/dev/client-bridge-registry.d.ts +5 -0
  97. package/src/dev/client-bridge-registry.js +15 -0
  98. package/src/dev/dev-client-ownership.d.ts +7 -0
  99. package/src/dev/dev-client-ownership.js +6 -0
  100. package/src/dev/host-runtime.d.ts +3 -0
  101. package/src/dev/host-runtime.js +7 -0
  102. package/src/hmr/client/hmr-runtime.js +5 -2
  103. package/src/hmr/strategies/server-rendered-template-hmr-strategy.d.ts +17 -0
  104. package/src/hmr/strategies/server-rendered-template-hmr-strategy.js +29 -0
  105. package/src/integrations/ghtml/ghtml-renderer.d.ts +2 -6
  106. package/src/integrations/ghtml/ghtml-renderer.js +2 -51
  107. package/src/integrations/ghtml/ghtml.plugin.d.ts +3 -16
  108. package/src/integrations/ghtml/ghtml.plugin.js +7 -14
  109. package/src/plugins/define-integration.d.ts +26 -0
  110. package/src/plugins/define-integration.js +19 -0
  111. package/src/plugins/eco-component-meta-plugin.js +5 -8
  112. package/src/plugins/foreign-jsx-override-plugin.js +4 -6
  113. package/src/plugins/integration-plugin.d.ts +19 -9
  114. package/src/plugins/integration-plugin.js +7 -4
  115. package/src/plugins/jsx-import-source.utils.d.ts +8 -0
  116. package/src/plugins/jsx-import-source.utils.js +26 -0
  117. package/src/plugins/processor.d.ts +19 -4
  118. package/src/plugins/processor.js +22 -4
  119. package/src/plugins/source-transform.d.ts +31 -0
  120. package/src/plugins/source-transform.js +23 -1
  121. package/src/route-renderer/GRAPH.md +8 -8
  122. package/src/route-renderer/README.md +30 -28
  123. package/src/route-renderer/orchestration/component-graph-collectors.d.ts +10 -0
  124. package/src/route-renderer/orchestration/component-graph-collectors.js +143 -0
  125. package/src/route-renderer/orchestration/component-graph.d.ts +36 -0
  126. package/src/route-renderer/orchestration/component-graph.js +90 -0
  127. package/src/route-renderer/orchestration/component-render-context.d.ts +3 -10
  128. package/src/route-renderer/orchestration/component-render-context.js +3 -1
  129. package/src/route-renderer/orchestration/declared-ownership-graph.d.ts +1 -18
  130. package/src/route-renderer/orchestration/declared-ownership-graph.js +5 -31
  131. package/src/route-renderer/orchestration/document-shell-render.service.d.ts +54 -0
  132. package/src/route-renderer/orchestration/document-shell-render.service.js +54 -0
  133. package/src/route-renderer/orchestration/foreign-subtree-execution.service.d.ts +59 -29
  134. package/src/route-renderer/orchestration/foreign-subtree-execution.service.js +164 -35
  135. package/src/route-renderer/orchestration/global-injector-assets.service.d.ts +7 -0
  136. package/src/route-renderer/orchestration/global-injector-assets.service.js +32 -0
  137. package/src/route-renderer/orchestration/integration-renderer.d.ts +18 -54
  138. package/src/route-renderer/orchestration/integration-renderer.js +108 -194
  139. package/src/route-renderer/orchestration/integration-route-render-adapter.d.ts +38 -0
  140. package/src/route-renderer/orchestration/integration-route-render-adapter.js +27 -0
  141. package/src/route-renderer/orchestration/ownership-validation.service.d.ts +4 -0
  142. package/src/route-renderer/orchestration/ownership-validation.service.js +11 -1
  143. package/src/route-renderer/orchestration/page-browser-graph-contribution.loader.d.ts +9 -0
  144. package/src/route-renderer/orchestration/page-browser-graph-contribution.loader.js +7 -0
  145. package/src/route-renderer/orchestration/page-browser-graph.service.d.ts +25 -0
  146. package/src/route-renderer/orchestration/page-browser-graph.service.js +174 -0
  147. package/src/route-renderer/orchestration/render-output.utils.d.ts +2 -0
  148. package/src/route-renderer/orchestration/render-output.utils.js +4 -0
  149. package/src/route-renderer/orchestration/route-html-finalization.service.d.ts +17 -0
  150. package/src/route-renderer/orchestration/route-html-finalization.service.js +26 -0
  151. package/src/route-renderer/orchestration/route-prepared-options.builder.d.ts +24 -0
  152. package/src/route-renderer/orchestration/route-prepared-options.builder.js +52 -0
  153. package/src/route-renderer/orchestration/route-prepared-options.utils.d.ts +4 -0
  154. package/src/route-renderer/orchestration/route-prepared-options.utils.js +33 -0
  155. package/src/route-renderer/orchestration/route-render-orchestrator.d.ts +5 -38
  156. package/src/route-renderer/orchestration/route-render-orchestrator.js +51 -459
  157. package/src/route-renderer/orchestration/string-markup-renderer.d.ts +14 -0
  158. package/src/route-renderer/orchestration/string-markup-renderer.js +54 -0
  159. package/src/router/client/navigation-coordinator.d.ts +1 -1
  160. package/src/router/client/navigation-coordinator.js +12 -2
  161. package/src/services/assets/asset-processing-service/browser-runtime-asset.factory.d.ts +1 -0
  162. package/src/services/assets/asset-processing-service/browser-runtime-asset.factory.js +1 -0
  163. package/src/services/assets/asset-processing-service/browser-runtime-entry.factory.d.ts +4 -2
  164. package/src/services/assets/asset-processing-service/browser-runtime-entry.factory.js +27 -7
  165. package/src/services/assets/asset-processing-service/processors/script/file-script.processor.js +32 -14
  166. package/src/services/assets/asset-processing-service/processors/script/node-module-script.processor.js +17 -3
  167. package/src/services/assets/asset-processing-service/processors/stylesheet/content-stylesheet.processor.d.ts +0 -3
  168. package/src/services/assets/asset-processing-service/processors/stylesheet/content-stylesheet.processor.js +2 -31
  169. package/src/services/assets/asset-processing-service/processors/stylesheet/file-stylesheet.processor.d.ts +0 -3
  170. package/src/services/assets/asset-processing-service/processors/stylesheet/file-stylesheet.processor.js +2 -30
  171. package/src/services/assets/asset-processing-service/processors/stylesheet/stylesheet-processor-pipeline.d.ts +2 -0
  172. package/src/services/assets/asset-processing-service/processors/stylesheet/stylesheet-processor-pipeline.js +43 -0
  173. package/src/services/assets/browser-bundle.service.d.ts +3 -1
  174. package/src/services/assets/browser-bundle.service.js +17 -5
  175. package/src/services/html/html-transformer.service.d.ts +1 -1
  176. package/src/services/html/html-transformer.service.js +4 -4
  177. package/src/services/invalidation/development-invalidation.service.d.ts +10 -1
  178. package/src/services/invalidation/development-invalidation.service.js +31 -2
  179. package/src/services/module-loading/README.md +49 -0
  180. package/src/services/module-loading/app-server-module-transpiler.service.js +5 -17
  181. package/src/services/module-loading/page-module-import.service.d.ts +4 -1
  182. package/src/services/module-loading/page-module-import.service.js +61 -41
  183. package/src/services/module-loading/route-module-build-cache-registry.d.ts +24 -0
  184. package/src/services/module-loading/route-module-build-cache-registry.js +37 -0
  185. package/src/services/module-loading/route-module-build-cache.d.ts +4 -0
  186. package/src/services/module-loading/route-module-build-cache.js +38 -0
  187. package/src/services/module-loading/route-module-build-cache.store.d.ts +57 -0
  188. package/src/services/module-loading/route-module-build-cache.store.js +207 -0
  189. package/src/services/module-loading/route-module-build-manifest.d.ts +61 -0
  190. package/src/services/module-loading/route-module-build-manifest.js +116 -0
  191. package/src/services/module-loading/route-module-dependency-hasher.d.ts +81 -0
  192. package/src/services/module-loading/route-module-dependency-hasher.js +121 -0
  193. package/src/services/module-loading/server-module-transpiler.service.js +1 -1
  194. package/src/static-site-generator/README.md +33 -0
  195. package/src/static-site-generator/static-build-invalidation.d.ts +10 -0
  196. package/src/static-site-generator/static-build-invalidation.js +59 -0
  197. package/src/static-site-generator/static-export-context.d.ts +22 -0
  198. package/src/static-site-generator/static-export-context.js +0 -0
  199. package/src/static-site-generator/static-site-generator.d.ts +17 -20
  200. package/src/static-site-generator/static-site-generator.js +188 -85
  201. package/src/types/internal-types.d.ts +12 -9
  202. package/src/types/public-types.d.ts +87 -22
  203. package/src/utils/parse-cli-args.d.ts +1 -0
  204. package/src/utils/parse-cli-args.js +3 -0
  205. package/src/watchers/project-watcher.d.ts +14 -2
  206. package/src/watchers/project-watcher.js +50 -20
  207. package/src/build/rolldown-dev-build-adapter.d.ts +0 -82
  208. package/src/build/rolldown-dev-build-adapter.js +0 -166
  209. package/src/hmr/hmr.postcss.test.e2e.d.ts +0 -1
  210. package/src/hmr/hmr.postcss.test.e2e.js +0 -31
  211. package/src/hmr/hmr.test.e2e.d.ts +0 -1
  212. package/src/hmr/hmr.test.e2e.js +0 -43
  213. package/src/route-renderer/orchestration/ownership-planning.service.d.ts +0 -24
  214. package/src/route-renderer/orchestration/ownership-planning.service.js +0 -63
  215. package/src/route-renderer/orchestration/queued-foreign-subtree-resolution.service.d.ts +0 -91
  216. package/src/route-renderer/orchestration/queued-foreign-subtree-resolution.service.js +0 -170
@@ -9,12 +9,14 @@ export type BrowserRuntimeEntryModuleConfig = {
9
9
  * @remarks
10
10
  * Integrations use this helper when they need a browser runtime asset composed
11
11
  * from multiple bare specifiers but do not want to own temporary file assembly
12
- * logic themselves. The generated file lives under a cache directory inside the
13
- * consuming app root so repeated runs can reuse the same location.
12
+ * logic themselves. The generated file lives under the app work directory so
13
+ * repeated runs can reuse the same location without placing sources inside
14
+ * `node_modules`, which can cause bundlers to externalize bare imports.
14
15
  */
15
16
  export declare function createBrowserRuntimeEntryModule(options: {
16
17
  modules: BrowserRuntimeEntryModuleConfig[];
17
18
  fileName: string;
18
19
  rootDir?: string;
20
+ workDir?: string;
19
21
  cacheDirName?: string;
20
22
  }): string;
@@ -1,37 +1,57 @@
1
1
  import fs from "node:fs";
2
2
  import path from "node:path";
3
3
  import { createRequire } from "node:module";
4
+ import { DEFAULT_ECOPAGES_WORK_DIR } from "../../../config/constants.js";
4
5
  function createBrowserRuntimeEntryModule(options) {
6
+ if (options.modules.some((module) => !module.specifier.startsWith("node:")) && !options.rootDir) {
7
+ throw new Error("createBrowserRuntimeEntryModule requires rootDir to resolve package specifiers");
8
+ }
5
9
  const rootDir = options.rootDir ?? process.cwd();
10
+ const workDir = options.workDir ?? path.join(rootDir, DEFAULT_ECOPAGES_WORK_DIR);
6
11
  const artifactsDir = path.join(
7
- rootDir,
8
- "node_modules",
9
- ".cache",
12
+ workDir,
13
+ ".browser-runtime-entries",
10
14
  options.cacheDirName ?? "ecopages-browser-runtime"
11
15
  );
12
16
  fs.mkdirSync(artifactsDir, { recursive: true });
13
17
  const requireFromRoot = createRequire(path.join(rootDir, "package.json"));
14
18
  const seenExports = /* @__PURE__ */ new Set();
15
19
  const statements = [];
20
+ const filePath = path.join(artifactsDir, options.fileName);
21
+ const entryDir = path.dirname(filePath);
16
22
  for (const module of options.modules) {
23
+ const importSpecifier = resolveEntryImportSpecifier(module.specifier, requireFromRoot, entryDir);
17
24
  if (module.defaultExport) {
18
- statements.push(`import __ecopages_default_export__ from '${module.specifier}';`);
25
+ statements.push(`import __ecopages_default_export__ from '${importSpecifier}';`);
19
26
  statements.push("export default __ecopages_default_export__;");
20
27
  }
21
28
  const exportNames = getModuleExportNames(module.specifier, requireFromRoot).filter(
22
29
  (name) => !seenExports.has(name)
23
30
  );
24
31
  if (exportNames.length > 0) {
25
- statements.push(`export { ${exportNames.join(", ")} } from '${module.specifier}';`);
32
+ statements.push(`export { ${exportNames.join(", ")} } from '${importSpecifier}';`);
26
33
  for (const exportName of exportNames) {
27
34
  seenExports.add(exportName);
28
35
  }
29
36
  }
30
37
  }
31
- const filePath = path.join(artifactsDir, options.fileName);
32
- fs.writeFileSync(filePath, statements.join("\n"), "utf-8");
38
+ const content = statements.join("\n");
39
+ if (!fs.existsSync(filePath) || fs.readFileSync(filePath, "utf-8") !== content) {
40
+ fs.writeFileSync(filePath, content, "utf-8");
41
+ }
33
42
  return filePath;
34
43
  }
44
+ function resolveEntryImportSpecifier(specifier, requireFromRoot, entryDir) {
45
+ if (specifier.startsWith("node:") || specifier.startsWith("file:")) {
46
+ return specifier;
47
+ }
48
+ const resolvedPath = requireFromRoot.resolve(specifier);
49
+ let relativePath = path.relative(entryDir, resolvedPath).replace(/\\/g, "/");
50
+ if (!relativePath.startsWith(".")) {
51
+ relativePath = `./${relativePath}`;
52
+ }
53
+ return relativePath;
54
+ }
35
55
  function getModuleExportNames(specifier, requireFromRoot) {
36
56
  const moduleExports = requireFromRoot(specifier);
37
57
  return Object.keys(moduleExports).filter((name) => name !== "__esModule" && name !== "default").filter((name) => /^[$A-Z_a-z][$\w]*$/.test(name)).sort();
@@ -20,20 +20,38 @@ class FileScriptProcessor extends BaseScriptProcessor {
20
20
  }
21
21
  async process(dep) {
22
22
  if (this.hmrManager?.isEnabled() && !dep.inline) {
23
- const outputUrl = await this.hmrManager.registerScriptEntrypoint(dep.filepath);
24
- const outputFilepath = this.resolveHmrOutputFilepath(dep.filepath);
25
- return {
26
- filepath: outputFilepath ?? dep.filepath,
27
- sourceFilepath: dep.filepath,
28
- srcUrl: outputUrl,
29
- kind: "script",
30
- position: dep.position,
31
- attributes: dep.attributes,
32
- inline: false,
33
- excludeFromHtml: dep.excludeFromHtml,
34
- packageRole: dep.packageRole,
35
- bundledSourceFilepaths: dep.bundledSourceFilepaths
36
- };
23
+ const resolvedOutput = this.hmrManager.getResolvedScriptOutput?.(dep.filepath);
24
+ if (resolvedOutput) {
25
+ return {
26
+ filepath: resolvedOutput.outputPath,
27
+ sourceFilepath: dep.filepath,
28
+ srcUrl: resolvedOutput.outputUrl,
29
+ kind: "script",
30
+ position: dep.position,
31
+ attributes: dep.attributes,
32
+ inline: false,
33
+ excludeFromHtml: dep.excludeFromHtml,
34
+ packageRole: dep.packageRole,
35
+ bundledSourceFilepaths: dep.bundledSourceFilepaths
36
+ };
37
+ }
38
+ try {
39
+ const outputUrl = await this.hmrManager.registerScriptEntrypoint(dep.filepath);
40
+ const outputFilepath = this.resolveHmrOutputFilepath(dep.filepath);
41
+ return {
42
+ filepath: outputFilepath ?? dep.filepath,
43
+ sourceFilepath: dep.filepath,
44
+ srcUrl: outputUrl,
45
+ kind: "script",
46
+ position: dep.position,
47
+ attributes: dep.attributes,
48
+ inline: false,
49
+ excludeFromHtml: dep.excludeFromHtml,
50
+ packageRole: dep.packageRole,
51
+ bundledSourceFilepaths: dep.bundledSourceFilepaths
52
+ };
53
+ } catch {
54
+ }
37
55
  }
38
56
  const content = fileSystem.readFileSync(dep.filepath);
39
57
  const shouldBundle = this.shouldBundle(dep);
@@ -8,19 +8,33 @@ class NodeModuleScriptProcessor extends BaseScriptProcessor {
8
8
  const modulePath = this.resolveModulePath(dep.importPath, this.appConfig.rootDir);
9
9
  const moduleName = path.basename(modulePath);
10
10
  const filename = dep.name ?? `nm-${moduleName}`;
11
+ const shouldBundle = this.shouldBundle(dep);
11
12
  const configHash = this.generateHash(
12
- JSON.stringify({ inline: dep.inline, minify: !dep.inline && this.isProduction, opts: dep.bundleOptions })
13
+ JSON.stringify({
14
+ bundle: shouldBundle,
15
+ inline: dep.inline,
16
+ minify: shouldBundle && !dep.inline && this.isProduction,
17
+ opts: dep.bundleOptions
18
+ })
13
19
  );
14
20
  const cachekey = `${this.buildCacheKey(filename, this.generateHash(modulePath), dep)}:${configHash}`;
15
21
  return this.getOrProcess(cachekey, async () => {
16
- if (dep.inline) {
22
+ if (dep.inline || !shouldBundle) {
17
23
  const content = fileSystem.readFileAsBuffer(modulePath).toString();
24
+ const filepath = dep.inline ? void 0 : path.join(this.getAssetsDir(), "vendors", filename);
25
+ if (filepath) {
26
+ fileSystem.ensureDir(path.dirname(filepath));
27
+ if (!fileSystem.exists(filepath) || fileSystem.readFileAsBuffer(filepath).toString() !== content) {
28
+ fileSystem.copyFile(modulePath, filepath);
29
+ }
30
+ }
18
31
  return {
32
+ filepath,
19
33
  content,
20
34
  kind: dep.kind,
21
35
  position: dep.position,
22
36
  attributes: dep.attributes,
23
- inline: true,
37
+ inline: dep.inline,
24
38
  excludeFromHtml: dep.excludeFromHtml,
25
39
  packageRole: dep.packageRole,
26
40
  bundledSourceFilepaths: dep.bundledSourceFilepaths
@@ -1,8 +1,5 @@
1
1
  import type { ContentStylesheetAsset, ProcessedAsset } from '../../assets.types.js';
2
2
  import { BaseProcessor } from '../base/base-processor.js';
3
3
  export declare class ContentStylesheetProcessor extends BaseProcessor<ContentStylesheetAsset> {
4
- private static readonly PROCESSABLE_STYLESHEET_EXTENSIONS;
5
- private isProcessableStylesheet;
6
- private applyStylesheetProcessors;
7
4
  process(dep: ContentStylesheetAsset): Promise<ProcessedAsset>;
8
5
  }
@@ -1,40 +1,11 @@
1
1
  import path from "node:path";
2
2
  import { fileSystem } from "@ecopages/file-system";
3
3
  import { BaseProcessor } from "../base/base-processor.js";
4
+ import { applyStylesheetProcessors } from "./stylesheet-processor-pipeline.js";
4
5
  class ContentStylesheetProcessor extends BaseProcessor {
5
- static PROCESSABLE_STYLESHEET_EXTENSIONS = /* @__PURE__ */ new Set([".css", ".scss", ".sass", ".less"]);
6
- isProcessableStylesheet(filepath) {
7
- return ContentStylesheetProcessor.PROCESSABLE_STYLESHEET_EXTENSIONS.has(path.extname(filepath));
8
- }
9
- async applyStylesheetProcessors(content, filepath) {
10
- if (!this.isProcessableStylesheet(filepath)) {
11
- return content;
12
- }
13
- let transformedContent = content;
14
- const processors = this.appConfig.processors ? Array.from(this.appConfig.processors.values()) : [];
15
- for (const processor of processors) {
16
- const hasCapabilities = processor.getAssetCapabilities().length > 0;
17
- const canProcessStylesheet = processor.canProcessAsset("stylesheet", filepath);
18
- if (!canProcessStylesheet && (hasCapabilities || !processor.getName().includes("postcss"))) {
19
- continue;
20
- }
21
- if (!processor.matchesFileFilter(filepath)) {
22
- continue;
23
- }
24
- const result = await processor.process(transformedContent, filepath);
25
- if (typeof result === "string") {
26
- transformedContent = result;
27
- continue;
28
- }
29
- if (result instanceof Buffer) {
30
- transformedContent = result.toString();
31
- }
32
- }
33
- return transformedContent;
34
- }
35
6
  async process(dep) {
36
7
  const virtualFilepath = path.join(this.appConfig.absolutePaths.distDir, "styles", "page-bundle.css");
37
- const processedContent = await this.applyStylesheetProcessors(dep.content, virtualFilepath);
8
+ const processedContent = await applyStylesheetProcessors(this.appConfig, dep.content, virtualFilepath);
38
9
  const hash = this.generateHash(processedContent);
39
10
  const filename = `style-${hash}.css`;
40
11
  const cachekey = this.buildCacheKey(filename, hash, dep);
@@ -1,9 +1,6 @@
1
1
  import type { FileStylesheetAsset, ProcessedAsset } from '../../assets.types.js';
2
2
  import { BaseProcessor } from '../base/base-processor.js';
3
3
  export declare class FileStylesheetProcessor extends BaseProcessor<FileStylesheetAsset> {
4
- private static readonly PROCESSABLE_STYLESHEET_EXTENSIONS;
5
4
  getStyleContent: (srcUrl: string) => Buffer;
6
- private isProcessableStylesheet;
7
- private applyStylesheetProcessors;
8
5
  process(dep: FileStylesheetAsset): Promise<ProcessedAsset>;
9
6
  }
@@ -1,43 +1,15 @@
1
1
  import path from "node:path";
2
2
  import { fileSystem } from "@ecopages/file-system";
3
3
  import { BaseProcessor } from "../base/base-processor.js";
4
+ import { applyStylesheetProcessors } from "./stylesheet-processor-pipeline.js";
4
5
  class FileStylesheetProcessor extends BaseProcessor {
5
- static PROCESSABLE_STYLESHEET_EXTENSIONS = /* @__PURE__ */ new Set([".css", ".scss", ".sass", ".less"]);
6
6
  getStyleContent = (srcUrl) => {
7
7
  return fileSystem.readFileAsBuffer(srcUrl);
8
8
  };
9
- isProcessableStylesheet(filepath) {
10
- return FileStylesheetProcessor.PROCESSABLE_STYLESHEET_EXTENSIONS.has(path.extname(filepath));
11
- }
12
- async applyStylesheetProcessors(content, filepath) {
13
- if (!this.isProcessableStylesheet(filepath)) {
14
- return content;
15
- }
16
- let transformedContent = content;
17
- for (const processor of this.appConfig.processors.values()) {
18
- const hasCapabilities = processor.getAssetCapabilities().length > 0;
19
- const canProcessStylesheet = processor.canProcessAsset("stylesheet", filepath);
20
- if (!canProcessStylesheet && (hasCapabilities || !processor.getName().includes("postcss"))) {
21
- continue;
22
- }
23
- if (!processor.matchesFileFilter(filepath)) {
24
- continue;
25
- }
26
- const result = await processor.process(transformedContent, filepath);
27
- if (typeof result === "string") {
28
- transformedContent = result;
29
- continue;
30
- }
31
- if (result instanceof Buffer) {
32
- transformedContent = result.toString();
33
- }
34
- }
35
- return transformedContent;
36
- }
37
9
  async process(dep) {
38
10
  const buffer = this.getStyleContent(dep.filepath);
39
11
  const rawContent = buffer.toString();
40
- const processedContent = await this.applyStylesheetProcessors(rawContent, dep.filepath);
12
+ const processedContent = await applyStylesheetProcessors(this.appConfig, rawContent, dep.filepath);
41
13
  const hash = this.generateHash(processedContent);
42
14
  const cachekey = this.buildCacheKey(dep.filepath, hash, dep);
43
15
  return this.getOrProcess(cachekey, () => {
@@ -0,0 +1,2 @@
1
+ import type { EcoPagesAppConfig } from '../../../../../types/internal-types.js';
2
+ export declare function applyStylesheetProcessors(appConfig: EcoPagesAppConfig, content: string, filepath: string): Promise<string>;
@@ -0,0 +1,43 @@
1
+ import path from "node:path";
2
+ const PROCESSABLE_STYLESHEET_EXTENSIONS = /* @__PURE__ */ new Set([".css", ".scss", ".sass", ".less"]);
3
+ function isProcessableStylesheet(filepath) {
4
+ return PROCESSABLE_STYLESHEET_EXTENSIONS.has(path.extname(filepath));
5
+ }
6
+ function shouldRunStylesheetProcessor(processor, filepath) {
7
+ const hasCapabilities = processor.getAssetCapabilities().length > 0;
8
+ const canProcessStylesheet = processor.canProcessAsset("stylesheet", filepath);
9
+ if (canProcessStylesheet) {
10
+ return true;
11
+ }
12
+ if (hasCapabilities) {
13
+ return false;
14
+ }
15
+ return processor.getName().includes("postcss");
16
+ }
17
+ async function applyStylesheetProcessors(appConfig, content, filepath) {
18
+ if (!isProcessableStylesheet(filepath)) {
19
+ return content;
20
+ }
21
+ let transformedContent = content;
22
+ const processors = appConfig.processors ? Array.from(appConfig.processors.values()) : [];
23
+ for (const processor of processors) {
24
+ if (!shouldRunStylesheetProcessor(processor, filepath)) {
25
+ continue;
26
+ }
27
+ if (!processor.matchesFileFilter(filepath)) {
28
+ continue;
29
+ }
30
+ const result = await processor.process(transformedContent, filepath);
31
+ if (typeof result === "string") {
32
+ transformedContent = result;
33
+ continue;
34
+ }
35
+ if (result instanceof Buffer) {
36
+ transformedContent = result.toString();
37
+ }
38
+ }
39
+ return transformedContent;
40
+ }
41
+ export {
42
+ applyStylesheetProcessors
43
+ };
@@ -16,6 +16,7 @@ export type BrowserBundleOptions = {
16
16
  externalPackages?: boolean;
17
17
  external?: string[];
18
18
  plugins?: EcoBuildPlugin[];
19
+ executor?: 'build' | 'hmr';
19
20
  [key: string]: unknown;
20
21
  profile: BuildTranspileProfile;
21
22
  excludeAppBuildPlugins?: string[];
@@ -65,7 +66,8 @@ export declare class BrowserBundleService implements BrowserBundleExecutor {
65
66
  * @remarks
66
67
  * Browser defaults and app-owned browser build plugins are applied here so HMR
67
68
  * and runtime asset generation do not have to recreate that policy at each call
68
- * site.
69
+ * site. Also forwards {@link getAppSourceTransforms | app source transforms} so
70
+ * metadata injection runs after boundary/runtime `onLoad` rewrites.
69
71
  */
70
72
  bundle(options: BrowserBundleOptions): Promise<BuildResult>;
71
73
  bundleGroupedEntries(entries: BrowserBundleGroupedEntry[], options: BrowserBundleGroupedOptions): Promise<BuildResult>;
@@ -1,5 +1,14 @@
1
- import { getAppBrowserBuildPlugins, getAppBuildExecutor, getAppTranspileOptions } from "../../build/build-adapter.js";
1
+ import { getAppBrowserBuildPlugins, getAppTranspileOptions } from "../../build/build-adapter.js";
2
+ import { requireBuildRuntime } from "../../build/build-runtime.js";
2
3
  import { mergeEcoBuildPlugins } from "../../build/build-manifest.js";
4
+ import { getAppSourceTransforms } from "../../plugins/source-transform.js";
5
+ function resolveBrowserBundleExecutor(appConfig, profile, executor) {
6
+ const buildRuntime = requireBuildRuntime(appConfig);
7
+ if (executor === "hmr" && profile === "hmr-entrypoint") {
8
+ return buildRuntime.getProfile("browser-hmr");
9
+ }
10
+ return buildRuntime.getProfile("route-module");
11
+ }
3
12
  class BrowserBundleService {
4
13
  appConfig;
5
14
  /**
@@ -14,19 +23,22 @@ class BrowserBundleService {
14
23
  * @remarks
15
24
  * Browser defaults and app-owned browser build plugins are applied here so HMR
16
25
  * and runtime asset generation do not have to recreate that policy at each call
17
- * site.
26
+ * site. Also forwards {@link getAppSourceTransforms | app source transforms} so
27
+ * metadata injection runs after boundary/runtime `onLoad` rewrites.
18
28
  */
19
29
  async bundle(options) {
20
- const { profile, excludeAppBuildPlugins, plugins, ...rawBuildOptions } = options;
30
+ const { profile, excludeAppBuildPlugins, plugins, executor = "hmr", ...rawBuildOptions } = options;
21
31
  const appBrowserPlugins = getAppBrowserBuildPlugins(this.appConfig);
22
32
  const filteredAppBrowserPlugins = excludeAppBuildPlugins && excludeAppBuildPlugins.length > 0 ? appBrowserPlugins.filter((plugin) => !excludeAppBuildPlugins.includes(plugin.name)) : appBrowserPlugins;
23
33
  const request = {
24
34
  ...rawBuildOptions,
25
35
  entrypoints: options.entrypoints,
26
36
  ...getAppTranspileOptions(this.appConfig, profile),
27
- plugins: mergeEcoBuildPlugins(plugins, filteredAppBrowserPlugins)
37
+ plugins: mergeEcoBuildPlugins(plugins, filteredAppBrowserPlugins),
38
+ sourceTransforms: getAppSourceTransforms(this.appConfig)
28
39
  };
29
- return await getAppBuildExecutor(this.appConfig).build(request);
40
+ const buildExecutor = resolveBrowserBundleExecutor(this.appConfig, profile, executor);
41
+ return await buildExecutor.build(request);
30
42
  }
31
43
  async bundleGroupedEntries(entries, options) {
32
44
  const request = {
@@ -83,7 +83,7 @@ export declare class HtmlTransformerService {
83
83
  * string-based fallback remains in place for runtimes that cannot provide one
84
84
  * of those rewriter implementations.
85
85
  */
86
- transform(res: Response, contributions?: HtmlDocumentContribution[]): Promise<Response>;
86
+ transform(res: Response, contributions?: HtmlDocumentContribution[], pagePackage?: PagePackageResult): Promise<Response>;
87
87
  /**
88
88
  * Splits processed assets into head and body injection groups.
89
89
  */
@@ -188,8 +188,8 @@ class HtmlTransformerService {
188
188
  * string-based fallback remains in place for runtimes that cannot provide one
189
189
  * of those rewriter implementations.
190
190
  */
191
- async transform(res, contributions = []) {
192
- const { head, body } = this.groupDependenciesByPosition();
191
+ async transform(res, contributions = [], pagePackage) {
192
+ const { head, body } = this.groupDependenciesByPosition(pagePackage);
193
193
  const { headPrepend, headAppend, bodyPrepend, bodyAppend } = this.groupContributionsByPlacement(contributions);
194
194
  const htmlRewriter = await this.htmlRewriterProvider.createHtmlRewriter();
195
195
  if (htmlRewriter) {
@@ -239,8 +239,8 @@ class HtmlTransformerService {
239
239
  /**
240
240
  * Splits processed assets into head and body injection groups.
241
241
  */
242
- groupDependenciesByPosition() {
243
- const dependencies = this.pagePackage ? this.resolvePagePackageHtmlDependencies(this.pagePackage) : this.processedDependencies;
242
+ groupDependenciesByPosition(pagePackageOverride) {
243
+ const dependencies = pagePackageOverride ? this.resolvePagePackageHtmlDependencies(pagePackageOverride) : this.pagePackage ? this.resolvePagePackageHtmlDependencies(this.pagePackage) : this.processedDependencies;
244
244
  return dependencies.reduce(
245
245
  (acc, dep) => {
246
246
  if (dep.kind === "script") {
@@ -1,5 +1,5 @@
1
1
  import type { EcoPagesAppConfig } from '../../types/internal-types.js';
2
- export type DevelopmentInvalidationCategory = 'public-asset' | 'additional-watch' | 'include-source' | 'route-source' | 'processor-owned-asset' | 'server-source' | 'other';
2
+ export type DevelopmentInvalidationCategory = 'public-asset' | 'additional-watch' | 'include-source' | 'explicit-server-view' | 'route-source' | 'processor-owned-asset' | 'server-source' | 'other';
3
3
  /**
4
4
  * Framework-owned invalidation plan for one changed file.
5
5
  *
@@ -62,6 +62,15 @@ export declare class DevelopmentInvalidationService {
62
62
  * Returns whether the file is an include/template source file.
63
63
  */
64
64
  isIncludeSourceFile(filePath: string): boolean;
65
+ /**
66
+ * Returns whether the file is an explicit server-rendered view module.
67
+ *
68
+ * @remarks
69
+ * These modules are typically registered through `renderServerModule` in
70
+ * `app.ts` rather than the filesystem router. They need a full browser reload
71
+ * because their HTML is produced on the server, not through client HMR entrypoints.
72
+ */
73
+ isExplicitServerViewFile(filePath: string): boolean;
65
74
  /**
66
75
  * Returns whether the file is a server-executed source module outside the
67
76
  * special route/include buckets.
@@ -55,8 +55,18 @@ class DevelopmentInvalidationService {
55
55
  category: "include-source",
56
56
  invalidateServerModules: true,
57
57
  refreshRoutes: false,
58
- reloadBrowser: true,
59
- delegateToHmr: false,
58
+ reloadBrowser: false,
59
+ delegateToHmr: true,
60
+ processorHandledAsset: false
61
+ };
62
+ }
63
+ if (this.isExplicitServerViewFile(filePath)) {
64
+ return {
65
+ category: "explicit-server-view",
66
+ invalidateServerModules: true,
67
+ refreshRoutes: false,
68
+ reloadBrowser: false,
69
+ delegateToHmr: true,
60
70
  processorHandledAsset: false
61
71
  };
62
72
  }
@@ -148,6 +158,25 @@ class DevelopmentInvalidationService {
148
158
  }
149
159
  return /\.(?:[cm]?ts|[jt]sx?|mdx)$/u.test(resolvedPath);
150
160
  }
161
+ /**
162
+ * Returns whether the file is an explicit server-rendered view module.
163
+ *
164
+ * @remarks
165
+ * These modules are typically registered through `renderServerModule` in
166
+ * `app.ts` rather than the filesystem router. They need a full browser reload
167
+ * because their HTML is produced on the server, not through client HMR entrypoints.
168
+ */
169
+ isExplicitServerViewFile(filePath) {
170
+ const resolvedPath = path.resolve(filePath);
171
+ const viewsDir = path.join(this.appConfig.absolutePaths.srcDir, "views");
172
+ if (resolvedPath !== viewsDir && !resolvedPath.startsWith(`${viewsDir}${path.sep}`)) {
173
+ return false;
174
+ }
175
+ if (this.appConfig.templatesExt.some((extension) => resolvedPath.endsWith(extension))) {
176
+ return true;
177
+ }
178
+ return /\.(?:[cm]?ts|[jt]sx?|mdx)$/u.test(resolvedPath);
179
+ }
151
180
  /**
152
181
  * Returns whether the file is a server-executed source module outside the
153
182
  * special route/include buckets.
@@ -0,0 +1,49 @@
1
+ # Module Loading
2
+
3
+ Server-side source loading for framework-owned page modules, includes, and related templates.
4
+
5
+ ## Import stack
6
+
7
+ ```
8
+ Call site (route scan, renderer, SSG, API)
9
+ └─ AppModuleLoader.importModule() app-server-module-transpiler.service.ts
10
+ ├─ merges server build plugins + JSX ownership plugins
11
+ ├─ resolves route-module BuildExecutor
12
+ └─ PageModuleImportService.importModule()
13
+ ├─ dev + host loader → host runtime (Node only, when configured)
14
+ ├─ production disk cache → route-module build cache
15
+ ├─ unified pages graph → prebuilt chunk import
16
+ └─ Rolldown per-page build → dynamic import of transpiled output
17
+ ```
18
+
19
+ `ServerModuleTranspiler` is a thin wrapper that injects `rootDir`, optional default plugins, and invalidation version into the same `PageModuleImportService` path. App code should prefer `getAppModuleLoader(appConfig)` or `getAppServerModuleTranspiler(appConfig)`.
20
+
21
+ ## Host vs app ownership
22
+
23
+ | Path | When |
24
+ | ----------------------- | -------------------------------------------------------------------------------------------- |
25
+ | Host loader | `appConfig.runtime.hostModuleLoader` set (Vite host) and file supports direct source loading |
26
+ | Ecopages build pipeline | Framework-owned template files under `pages/`, `includes/`, etc. |
27
+
28
+ `shouldAppUseHostModuleLoader()` encodes the directory + extension rules. Bun always uses the build pipeline today.
29
+
30
+ ## Caching layers
31
+
32
+ 1. **In-memory promise cache** (`PageModuleImportService.importCache`) — keyed by file path, resolved `outdir`, JSX/plugin inputs, file hash, and invalidation version. Cleared by `invalidateDevelopmentGraph()`.
33
+ 2. **Disk transpile cache** (`.eco/.server-modules/.build-cache.json`) — production only; see route-module build cache slice.
34
+ 3. **Unified graph manifest** — production static export fast path; see build layer docs.
35
+
36
+ ## Files
37
+
38
+ | File | Role |
39
+ | ----------------------------------------- | --------------------------------------------------------- |
40
+ | `page-module-import.service.ts` | Core import/cache/build orchestration |
41
+ | `app-module-loader.service.ts` | App-facing loader interface |
42
+ | `app-server-module-transpiler.service.ts` | Factory for app-scoped loader + transpiler |
43
+ | `server-module-transpiler.service.ts` | Injectable transpiler boundary for tests and bootstrap |
44
+ | `host-module-loader-registry.ts` | Process-global host loader fallback for embedded runtimes |
45
+ | `source-module-support.ts` | Extension allowlist for host direct loading |
46
+
47
+ ## Development invalidation
48
+
49
+ `DevelopmentInvalidationService.invalidateServerModules()` bumps the app-owned invalidation version and calls `appModuleLoader.invalidateDevelopmentGraph()`, which clears the in-memory import cache and increments the per-service invalidation counter used in cache keys and dev `?update=` query params.
@@ -1,5 +1,6 @@
1
- import { getAppBuildExecutor, getAppServerBuildPlugins } from "../../build/build-adapter.js";
2
- import { createForeignJsxOverridePlugin } from "../../plugins/foreign-jsx-override-plugin.js";
1
+ import { getAppServerBuildPlugins } from "../../build/build-adapter.js";
2
+ import { requireBuildRuntime } from "../../build/build-runtime.js";
3
+ import { getJsxOwnershipPlugins } from "../../build/jsx-ownership-plugins.js";
3
4
  import path from "node:path";
4
5
  import { DevelopmentInvalidationService } from "../invalidation/development-invalidation.service.js";
5
6
  import {} from "./app-module-loader.service.js";
@@ -37,22 +38,9 @@ function setAppHostModuleLoader(appConfig, hostModuleLoader) {
37
38
  hostModuleLoader
38
39
  };
39
40
  }
40
- function getJsxOwnershipPlugins(appConfig) {
41
- const jsxExtensions = (appConfig.integrations ?? []).filter((integration) => integration.jsxImportSource).flatMap(
42
- (integration) => integration.extensions.filter((extension) => extension.endsWith(".tsx") || extension.endsWith(".jsx")).map((extension) => ({ integration, extension }))
43
- ).sort((left, right) => right.extension.length - left.extension.length);
44
- return jsxExtensions.map(
45
- ({ integration, extension }) => createForeignJsxOverridePlugin({
46
- hostJsxImportSource: integration.jsxImportSource,
47
- foreignExtensions: [extension],
48
- excludeExtensions: jsxExtensions.filter((candidate) => candidate.extension.length > extension.length).filter((candidate) => candidate.extension.endsWith(extension)).map((candidate) => candidate.extension),
49
- name: `ecopages-jsx-ownership-${integration.name}-${extension.replace(/[^a-zA-Z0-9]+/g, "-")}`
50
- })
51
- );
52
- }
53
41
  function createAppModuleLoader(appConfig) {
54
42
  const invalidationService = new DevelopmentInvalidationService(appConfig);
55
- const pageModuleImportService = new PageModuleImportService({
43
+ const pageModuleImportService = new PageModuleImportService(appConfig, {
56
44
  canLoadSourceModuleFromHost: (filePath) => shouldAppUseHostModuleLoader(appConfig, filePath),
57
45
  getHostModuleLoader: () => getAppHostModuleLoader(appConfig)
58
46
  });
@@ -69,7 +57,7 @@ function createAppModuleLoader(appConfig) {
69
57
  return await pageModuleImportService.importModule({
70
58
  ...options,
71
59
  ...mergedPlugins.length > 0 ? { plugins: mergedPlugins } : {},
72
- buildExecutor: options.buildExecutor ?? getAppBuildExecutor(appConfig),
60
+ buildExecutor: options.buildExecutor ?? requireBuildRuntime(appConfig).getProfile("route-module"),
73
61
  invalidationVersion
74
62
  });
75
63
  },
@@ -1,5 +1,6 @@
1
1
  import { build, type BuildExecutor, type BuildResult } from '../../build/build-adapter.js';
2
2
  import type { EcoBuildPlugin } from '../../build/build-types.js';
3
+ import type { EcoPagesAppConfig } from '../../types/internal-types.js';
3
4
  import type { SourceModuleLoaderFactory } from './module-loading-types.js';
4
5
  interface PageModuleImportBaseOptions {
5
6
  filePath: string;
@@ -59,10 +60,11 @@ export interface PageModuleImportDependencies {
59
60
  * transpilation settings, and error semantics across the different callers.
60
61
  */
61
62
  export declare class PageModuleImportService {
63
+ private readonly appConfig?;
62
64
  private readonly dependencies;
63
65
  private readonly importCache;
64
66
  private developmentInvalidationVersion;
65
- constructor(dependencies?: Partial<PageModuleImportDependencies>);
67
+ constructor(appConfig?: EcoPagesAppConfig, dependencies?: Partial<PageModuleImportDependencies>);
66
68
  /**
67
69
  * Clears the shared import cache used by framework-owned page-module loads.
68
70
  */
@@ -91,5 +93,6 @@ export declare class PageModuleImportService {
91
93
  */
92
94
  importModule<T = unknown>(options: PageModuleBuildImportOptions): Promise<T>;
93
95
  private loadModule;
96
+ private getRouteModuleBuildCache;
94
97
  }
95
98
  export {};