veryfront 0.1.825 → 0.1.827

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.
package/esm/deno.js CHANGED
@@ -1,6 +1,6 @@
1
1
  export default {
2
2
  "name": "veryfront",
3
- "version": "0.1.825",
3
+ "version": "0.1.827",
4
4
  "license": "Apache-2.0",
5
5
  "nodeModulesDir": "auto",
6
6
  "minimumDependencyAge": {
@@ -1 +1 @@
1
- {"version":3,"file":"output-generator.d.ts","sourceRoot":"","sources":["../../../../../src/src/build/production-build/build/output-generator.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACzE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAY1F,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4CAA4C,CAAC;AAEvF,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,cAAc,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB,SAAS,EAAE,YAAY,EAAE,CAAC;IAC1B,KAAK,EAAE,UAAU,CAAC;IAClB,eAAe,EAAE,OAAO,CAAC;IACzB,cAAc,EAAE,OAAO,CAAC;IACxB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,aAAa,EAAE,aAAa,GAAG,IAAI,CAAC;IACpC,MAAM,EAAE,OAAO,CAAC;IAChB,oBAAoB,CAAC,EAAE,oBAAoB,GAAG,IAAI,CAAC;CACpD;AAED;;GAEG;AACH,wBAAsB,qBAAqB,CACzC,OAAO,EAAE,cAAc,EACvB,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,OAAO,GACd,OAAO,CAAC,IAAI,CAAC,CAmBf;AAED;;GAEG;AACH,wBAAsB,gCAAgC,CACpD,OAAO,EAAE,sBAAsB,GAC9B,OAAO,CAAC,IAAI,CAAC,CAgCf;AAED;;GAEG;AACH,wBAAsB,qBAAqB,CACzC,OAAO,EAAE,cAAc,EACvB,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,OAAO,GACd,OAAO,CAAC,IAAI,CAAC,CAGf;AAED;;GAEG;AACH,wBAAgB,UAAU,CACxB,OAAO,EAAE,cAAc,EACvB,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,OAAO,GACd,OAAO,CAAC;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,CAAC,CAEhD;AAED;;GAEG;AACH,wBAAsB,kBAAkB,CAAC,OAAO,EAAE,sBAAsB,GAAG,OAAO,CAAC,IAAI,CAAC,CAmBvF"}
1
+ {"version":3,"file":"output-generator.d.ts","sourceRoot":"","sources":["../../../../../src/src/build/production-build/build/output-generator.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACzE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAe1F,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4CAA4C,CAAC;AAEvF,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,cAAc,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,SAAS,EAAE,CAAC;IACpB,SAAS,EAAE,YAAY,EAAE,CAAC;IAC1B,KAAK,EAAE,UAAU,CAAC;IAClB,eAAe,EAAE,OAAO,CAAC;IACzB,cAAc,EAAE,OAAO,CAAC;IACxB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,aAAa,EAAE,aAAa,GAAG,IAAI,CAAC;IACpC,MAAM,EAAE,OAAO,CAAC;IAChB,oBAAoB,CAAC,EAAE,oBAAoB,GAAG,IAAI,CAAC;CACpD;AAED;;GAEG;AACH,wBAAsB,qBAAqB,CACzC,OAAO,EAAE,cAAc,EACvB,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,OAAO,GACd,OAAO,CAAC,IAAI,CAAC,CAwBf;AAED;;GAEG;AACH,wBAAsB,gCAAgC,CACpD,OAAO,EAAE,sBAAsB,GAC9B,OAAO,CAAC,IAAI,CAAC,CAgCf;AAED;;GAEG;AACH,wBAAsB,qBAAqB,CACzC,OAAO,EAAE,cAAc,EACvB,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,OAAO,GACd,OAAO,CAAC,IAAI,CAAC,CAGf;AAED;;GAEG;AACH,wBAAgB,UAAU,CACxB,OAAO,EAAE,cAAc,EACvB,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,OAAO,GACd,OAAO,CAAC;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,CAAC,CAEhD;AAED;;GAEG;AACH,wBAAsB,kBAAkB,CAAC,OAAO,EAAE,sBAAsB,GAAG,OAAO,CAAC,IAAI,CAAC,CAmBvF"}
@@ -11,7 +11,7 @@
11
11
  import { serverLogger as logger } from "../../../utils/index.js";
12
12
  import { join } from "../../../platform/compat/path/index.js";
13
13
  import { generateServiceWorker } from "../../../server/build-service-worker.js";
14
- import { generateProdHydrationModule } from "../../../html/hydration-script-builder/prod-scripts.js";
14
+ import { generateProdHydrationModule, getProdHydrationModulePath, } from "../../../html/hydration-script-builder/prod-scripts.js";
15
15
  import { copyStaticAssets } from "../asset-generation.js";
16
16
  import { generateAppModule, generateClientModule, generatePrefetchScript, generateRouterScript, } from "../client-runtime.js";
17
17
  import { generateLocalReleaseAssetManifest } from "../local-release-assets.js";
@@ -27,7 +27,9 @@ export async function generateClientScripts(adapter, outputDir, dryRun) {
27
27
  await adapter.fs.writeFile(join(outputDir, "_veryfront/client.js"), await generateClientModule());
28
28
  await adapter.fs.writeFile(join(outputDir, "_veryfront/router.js"), await generateRouterScript(adapter));
29
29
  await adapter.fs.writeFile(join(outputDir, "_veryfront/prefetch.js"), await generatePrefetchScript(adapter));
30
- await adapter.fs.writeFile(join(outputDir, "_veryfront/hydration-runtime.js"), generateProdHydrationModule());
30
+ const hydrationRuntime = generateProdHydrationModule();
31
+ await adapter.fs.writeFile(join(outputDir, "_veryfront/hydration-runtime.js"), hydrationRuntime);
32
+ await adapter.fs.writeFile(join(outputDir, getProdHydrationModulePath().slice(1)), hydrationRuntime);
31
33
  }
32
34
  /**
33
35
  * Generate manifest and service worker
@@ -9,7 +9,7 @@ import { getReadyManifestForRenderAsync } from "../release-assets/manifest-cache
9
9
  import { resolveManifestModuleUrl, resolveManifestRoutePreloadUrls, } from "../release-assets/html-consumption.js";
10
10
  import { routeForPage } from "../release-assets/route-path.js";
11
11
  import { buildNonceAttribute, escapeHTML } from "./html-escape.js";
12
- import { generateHydrationData, getDevScripts, getProdScripts, PROD_HYDRATION_MODULE_PATH, } from "./hydration-script-builder/index.js";
12
+ import { generateHydrationData, getDevScripts, getProdHydrationModulePath, getProdScripts, } from "./hydration-script-builder/index.js";
13
13
  import { getPreviewStylesheetLink, getStudioScripts } from "./dev-scripts.js";
14
14
  import { processMetadata } from "./metadata-builder.js";
15
15
  import { extractCandidates, getDevStyles as getErrorOverlayStyles, getProjectCSS, } from "./styles-builder/index.js";
@@ -169,7 +169,7 @@ async function generateHTMLShellPartsImpl(meta, options, params, props, contentF
169
169
  : "";
170
170
  const prodHydrationModulePreload = useDevScripts
171
171
  ? ""
172
- : `<link rel="modulepreload" href="${PROD_HYDRATION_MODULE_PATH}">`;
172
+ : `<link rel="modulepreload" href="${getProdHydrationModulePath()}">`;
173
173
  const nonceAttr = buildNonceAttribute(nonce);
174
174
  // Expose project slug for runtime error overlay "Fix in Veryfront" button
175
175
  const overlaySlug = options.projectId || meta.slug;
@@ -9,6 +9,6 @@ export { getDevScripts } from "./dev-scripts.js";
9
9
  export { generateDevErrorLoggerScript } from "./dev-error-logger.js";
10
10
  export { generateDevComponentManifestScript } from "./dev-component-manifest.js";
11
11
  export { generateDevClientRendererScript } from "./dev-client-renderer.js";
12
- export { generateProdHydrationModule, getProdScripts, PROD_HYDRATION_MODULE_PATH, } from "./prod-scripts.js";
12
+ export { generateProdHydrationModule, getProdHydrationModulePath, getProdScripts, isVersionedProdHydrationModulePath, PROD_HYDRATION_MODULE_PATH, PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN, } from "./prod-scripts.js";
13
13
  export { generateProdHydrationScript } from "./prod-hydration.js";
14
14
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/src/html/hydration-script-builder/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EAAE,sBAAsB,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAE1E,OAAO,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;AAEtE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,4BAA4B,EAAE,MAAM,uBAAuB,CAAC;AACrE,OAAO,EAAE,kCAAkC,EAAE,MAAM,6BAA6B,CAAC;AACjF,OAAO,EAAE,+BAA+B,EAAE,MAAM,0BAA0B,CAAC;AAE3E,OAAO,EACL,2BAA2B,EAC3B,cAAc,EACd,0BAA0B,GAC3B,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,2BAA2B,EAAE,MAAM,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/src/html/hydration-script-builder/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,YAAY,EAAE,sBAAsB,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAE1E,OAAO,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;AAEtE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,4BAA4B,EAAE,MAAM,uBAAuB,CAAC;AACrE,OAAO,EAAE,kCAAkC,EAAE,MAAM,6BAA6B,CAAC;AACjF,OAAO,EAAE,+BAA+B,EAAE,MAAM,0BAA0B,CAAC;AAE3E,OAAO,EACL,2BAA2B,EAC3B,0BAA0B,EAC1B,cAAc,EACd,kCAAkC,EAClC,0BAA0B,EAC1B,4CAA4C,GAC7C,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,2BAA2B,EAAE,MAAM,qBAAqB,CAAC"}
@@ -8,5 +8,5 @@ export { getDevScripts } from "./dev-scripts.js";
8
8
  export { generateDevErrorLoggerScript } from "./dev-error-logger.js";
9
9
  export { generateDevComponentManifestScript } from "./dev-component-manifest.js";
10
10
  export { generateDevClientRendererScript } from "./dev-client-renderer.js";
11
- export { generateProdHydrationModule, getProdScripts, PROD_HYDRATION_MODULE_PATH, } from "./prod-scripts.js";
11
+ export { generateProdHydrationModule, getProdHydrationModulePath, getProdScripts, isVersionedProdHydrationModulePath, PROD_HYDRATION_MODULE_PATH, PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN, } from "./prod-scripts.js";
12
12
  export { generateProdHydrationScript } from "./prod-hydration.js";
@@ -1,4 +1,7 @@
1
1
  export declare const PROD_HYDRATION_MODULE_PATH = "/_veryfront/hydration-runtime.js";
2
+ export declare const PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN: RegExp;
2
3
  export declare function generateProdHydrationModule(): string;
4
+ export declare function getProdHydrationModulePath(): string;
5
+ export declare function isVersionedProdHydrationModulePath(pathname: string): boolean;
3
6
  export declare function getProdScripts(_slug: string, _params?: Record<string, string | string[]>, _props?: Record<string, unknown>, nonce?: string): string;
4
7
  //# sourceMappingURL=prod-scripts.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"prod-scripts.d.ts","sourceRoot":"","sources":["../../../../src/src/html/hydration-script-builder/prod-scripts.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,0BAA0B,qCAAqC,CAAC;AAE7E,wBAAgB,2BAA2B,IAAI,MAAM,CAUpD;AAED,wBAAgB,cAAc,CAC5B,KAAK,EAAE,MAAM,EACb,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,EAC3C,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,KAAK,CAAC,EAAE,MAAM,GACb,MAAM,CAGR"}
1
+ {"version":3,"file":"prod-scripts.d.ts","sourceRoot":"","sources":["../../../../src/src/html/hydration-script-builder/prod-scripts.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,0BAA0B,qCAAqC,CAAC;AAC7E,eAAO,MAAM,4CAA4C,QACH,CAAC;AAIvD,wBAAgB,2BAA2B,IAAI,MAAM,CAUpD;AAED,wBAAgB,0BAA0B,IAAI,MAAM,CAMnD;AAED,wBAAgB,kCAAkC,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAE5E;AAED,wBAAgB,cAAc,CAC5B,KAAK,EAAE,MAAM,EACb,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC,EAC3C,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChC,KAAK,CAAC,EAAE,MAAM,GACb,MAAM,CAGR"}
@@ -1,6 +1,9 @@
1
1
  import { getLoaderScript, getRendererScript, getRouterScript } from "./templates/index.js";
2
2
  import { buildNonceAttribute } from "../html-escape.js";
3
+ import { fnv1aHash } from "../../utils/hash-utils.js";
3
4
  export const PROD_HYDRATION_MODULE_PATH = "/_veryfront/hydration-runtime.js";
5
+ export const PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN = /^\/_veryfront\/hydration-runtime\.[0-9a-f]{8}\.js$/;
6
+ let cachedProdHydrationModulePath = null;
4
7
  export function generateProdHydrationModule() {
5
8
  return [
6
9
  `import * as React from 'react';`,
@@ -12,7 +15,17 @@ export function generateProdHydrationModule() {
12
15
  getRendererScript().trim(),
13
16
  ].join("\n\n");
14
17
  }
18
+ export function getProdHydrationModulePath() {
19
+ if (cachedProdHydrationModulePath)
20
+ return cachedProdHydrationModulePath;
21
+ const hash = fnv1aHash(generateProdHydrationModule()).padStart(8, "0");
22
+ cachedProdHydrationModulePath = `/_veryfront/hydration-runtime.${hash}.js`;
23
+ return cachedProdHydrationModulePath;
24
+ }
25
+ export function isVersionedProdHydrationModulePath(pathname) {
26
+ return PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN.test(pathname);
27
+ }
15
28
  export function getProdScripts(_slug, _params, _props, nonce) {
16
29
  const nonceAttr = buildNonceAttribute(nonce);
17
- return `\n <script type="module" src="${PROD_HYDRATION_MODULE_PATH}"${nonceAttr}></script>`;
30
+ return `\n <script type="module" src="${getProdHydrationModulePath()}"${nonceAttr}></script>`;
18
31
  }
@@ -1 +1 @@
1
- {"version":3,"file":"build-executor.d.ts","sourceRoot":"","sources":["../../../src/src/release-assets/build-executor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AA+BH,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AA0B/C,MAAM,WAAW,sBAAsB;IACrC,yDAAyD;IACzD,gBAAgB,EAAE,MAAM,CAAC;IACzB,oBAAoB;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,oBAAoB;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,iCAAiC;IACjC,cAAc,EAAE,MAAM,CAAC;IACvB,yDAAyD;IACzD,iBAAiB,EAAE,MAAM,CAAC;IAC1B,oCAAoC;IACpC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,cAAc,CAAC,EAAE,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CAAC;IAClC,cAAc,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACrC,GAAG,OAAO,CAAC;IACV,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;IAC5C,MAAM,EAAE,oBAAoB,EAAE,CAAC;IAC/B,IAAI,EAAE,MAAM,EAAE,CAAC;CAChB,CAAC,CAqCD;AAkDD;;;GAGG;AACH,wBAAsB,oBAAoB,CACxC,KAAK,EAAE,sBAAsB,EAC7B,OAAO,EAAE,MAAM,GACd,OAAO,CAAC,uBAAuB,CAAC,CA2ClC"}
1
+ {"version":3,"file":"build-executor.d.ts","sourceRoot":"","sources":["../../../src/src/release-assets/build-executor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AA+BH,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AA0B/C,MAAM,WAAW,sBAAsB;IACrC,yDAAyD;IACzD,gBAAgB,EAAE,MAAM,CAAC;IACzB,oBAAoB;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,oBAAoB;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,iCAAiC;IACjC,cAAc,EAAE,MAAM,CAAC;IACvB,yDAAyD;IACzD,iBAAiB,EAAE,MAAM,CAAC;IAC1B,oCAAoC;IACpC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,gDAAgD;IAChD,MAAM,EAAE,uBAAuB,CAAC;IAChC,sDAAsD;IAEtD,OAAO,EAAE,GAAG,CAAC;IACb;;;;OAIG;IACH,SAAS,CAAC,EAAE,qBAAqB,CAAC;IAClC;;;OAGG;IACH,iBAAiB,CAAC,EAAE,gCAAgC,CAAC;CACtD;AAED,MAAM,MAAM,qBAAqB,GAAG,CAClC,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,EAClB,UAAU,EAAE,MAAM,EAElB,OAAO,EAAE,GAAG,EAC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CAAC,uBAAuB,CAAC,CA2ClC"}
@@ -34,7 +34,7 @@ export { routeForPage } from "./route-path.js";
34
34
  const logger = serverLogger.component("release-asset-build");
35
35
  /** Browser module source extensions eligible for transform. */
36
36
  const BROWSER_MODULE_EXTENSIONS = [".tsx", ".ts", ".jsx", ".js", ".mdx"];
37
- /** Directories whose modules are part of the browser closure. */
37
+ /** Directories used as browser graph entry seeds. Imports may reach any project directory. */
38
38
  const BROWSER_MODULE_DIRS = ["pages/", "components/", "layouts/", "lib/", "src/"];
39
39
  const FRAMEWORK_MODULE_URL_PREFIX = "/_vf_modules/_veryfront/";
40
40
  const REACT_IMPORT_MAP_DEPENDENCIES = [
@@ -74,11 +74,17 @@ function sanitizeError(error) {
74
74
  return message.replace(/\/[^\s]+/g, "<path>").slice(0, 300);
75
75
  }
76
76
  /** True when a logical path is an eligible browser module. */
77
- function isBrowserModule(path) {
77
+ function isTransformableBrowserModule(path) {
78
78
  if (!BROWSER_MODULE_EXTENSIONS.some((ext) => path.endsWith(ext)))
79
79
  return false;
80
80
  if (path.endsWith(".d.ts"))
81
81
  return false;
82
+ return true;
83
+ }
84
+ /** True when a logical path should seed the browser module graph. */
85
+ function isBrowserModule(path) {
86
+ if (!isTransformableBrowserModule(path))
87
+ return false;
82
88
  return BROWSER_MODULE_DIRS.some((dir) => path.startsWith(dir));
83
89
  }
84
90
  /**
@@ -1037,53 +1043,33 @@ async function runBuildInner(input, tempDir, client, transform) {
1037
1043
  const knownPaths = new Set(sourceByPath.keys());
1038
1044
  const vendorHttpImports = input.vendorHttpImports ?? vendorHttpImportsWithCache;
1039
1045
  const vendorDependencies = isDependencyImportMapEnabled();
1040
- for (const [logicalPath, source] of sourceByPath) {
1041
- if (!isBrowserModule(logicalPath))
1042
- continue;
1043
- // M2: enforce client-side size limit before transform (source is a proxy;
1044
- // transformed output is checked after encoding below).
1045
- const sourceFile = join(tempDir, logicalPath);
1046
- let code;
1046
+ const transformingModules = new Set();
1047
+ async function transformProjectModule(logicalPath) {
1048
+ if (transformedModules.has(logicalPath) || transformingModules.has(logicalPath))
1049
+ return null;
1050
+ if (!isTransformableBrowserModule(logicalPath))
1051
+ return null;
1052
+ const source = sourceByPath.get(logicalPath);
1053
+ if (typeof source !== "string")
1054
+ return null;
1055
+ transformingModules.add(logicalPath);
1047
1056
  try {
1048
- code = await transform(source, sourceFile, tempDir, input.adapter, {
1049
- projectId: input.projectId,
1050
- dev: false,
1051
- ssr: false,
1052
- reactVersion: input.reactVersion,
1053
- });
1054
- }
1055
- catch (error) {
1056
- // Hard requirement: any module transform failure → report failed, stop.
1057
- const sanitized = sanitizeError(error);
1058
- logger.warn("Module transform failed during release asset build", {
1059
- path: logicalPath,
1060
- error: sanitized,
1061
- });
1062
- await client.reportReleaseAssetManifestState(input.releaseVersionRef, "failed", sanitized);
1063
- return {
1064
- success: false,
1065
- state: "failed",
1066
- moduleCount: 0,
1067
- cssCount: 0,
1068
- routeCount: 0,
1069
- gaps,
1070
- error: sanitized,
1071
- };
1072
- }
1073
- if (vendorDependencies) {
1057
+ // M2: enforce client-side size limit before transform (source is a proxy;
1058
+ // transformed output is checked after encoding below).
1059
+ const sourceFile = join(tempDir, logicalPath);
1060
+ let code;
1074
1061
  try {
1075
- const vendored = await vendorHttpImports(code, {
1076
- tempDir,
1062
+ code = await transform(source, sourceFile, tempDir, input.adapter, {
1063
+ projectId: input.projectId,
1064
+ dev: false,
1065
+ ssr: false,
1077
1066
  reactVersion: input.reactVersion,
1078
1067
  });
1079
- code = vendored.code;
1080
- for (const dependency of vendored.dependencies) {
1081
- addDependencyModule(dependencyModules, dependency);
1082
- }
1083
1068
  }
1084
1069
  catch (error) {
1070
+ // Hard requirement: any module transform failure -> report failed, stop.
1085
1071
  const sanitized = sanitizeError(error);
1086
- logger.warn("HTTP dependency vendoring failed during release asset build", {
1072
+ logger.warn("Module transform failed during release asset build", {
1087
1073
  path: logicalPath,
1088
1074
  error: sanitized,
1089
1075
  });
@@ -1098,8 +1084,54 @@ async function runBuildInner(input, tempDir, client, transform) {
1098
1084
  error: sanitized,
1099
1085
  };
1100
1086
  }
1087
+ if (vendorDependencies) {
1088
+ try {
1089
+ const vendored = await vendorHttpImports(code, {
1090
+ tempDir,
1091
+ reactVersion: input.reactVersion,
1092
+ });
1093
+ code = vendored.code;
1094
+ for (const dependency of vendored.dependencies) {
1095
+ addDependencyModule(dependencyModules, dependency);
1096
+ }
1097
+ }
1098
+ catch (error) {
1099
+ const sanitized = sanitizeError(error);
1100
+ logger.warn("HTTP dependency vendoring failed during release asset build", {
1101
+ path: logicalPath,
1102
+ error: sanitized,
1103
+ });
1104
+ await client.reportReleaseAssetManifestState(input.releaseVersionRef, "failed", sanitized);
1105
+ return {
1106
+ success: false,
1107
+ state: "failed",
1108
+ moduleCount: 0,
1109
+ cssCount: 0,
1110
+ routeCount: 0,
1111
+ gaps,
1112
+ error: sanitized,
1113
+ };
1114
+ }
1115
+ }
1116
+ transformedModules.set(logicalPath, { logicalPath, code });
1117
+ const imports = await collectProjectModuleImports(code, logicalPath, knownPaths);
1118
+ for (const importedPath of imports.values()) {
1119
+ const failure = await transformProjectModule(importedPath);
1120
+ if (failure)
1121
+ return failure;
1122
+ }
1101
1123
  }
1102
- transformedModules.set(logicalPath, { logicalPath, code });
1124
+ finally {
1125
+ transformingModules.delete(logicalPath);
1126
+ }
1127
+ return null;
1128
+ }
1129
+ for (const logicalPath of sourceByPath.keys()) {
1130
+ if (!isBrowserModule(logicalPath))
1131
+ continue;
1132
+ const failure = await transformProjectModule(logicalPath);
1133
+ if (failure)
1134
+ return failure;
1103
1135
  }
1104
1136
  if (vendorDependencies) {
1105
1137
  try {
@@ -1 +1 @@
1
- {"version":3,"file":"prod-hydration-module.handler.d.ts","sourceRoot":"","sources":["../../../../../src/src/server/handlers/request/prod-hydration-module.handler.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAmB,aAAa,EAAE,MAAM,aAAa,CAAC;AAqBnG,qBAAa,0BAA2B,SAAQ,WAAW;IACzD,QAAQ,EAAE,eAAe,CAOvB;IAEI,MAAM,CAAC,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC;CA2BxE"}
1
+ {"version":3,"file":"prod-hydration-module.handler.d.ts","sourceRoot":"","sources":["../../../../../src/src/server/handlers/request/prod-hydration-module.handler.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAmB,aAAa,EAAE,MAAM,aAAa,CAAC;AAuBnG,qBAAa,0BAA2B,SAAQ,WAAW;IACzD,QAAQ,EAAE,eAAe,CASvB;IAEI,MAAM,CAAC,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC;CAgCxE"}
@@ -1,5 +1,5 @@
1
1
  import { BaseHandler } from "../response/base.js";
2
- import { generateProdHydrationModule, PROD_HYDRATION_MODULE_PATH, } from "../../../html/hydration-script-builder/prod-scripts.js";
2
+ import { generateProdHydrationModule, isVersionedProdHydrationModulePath, PROD_HYDRATION_MODULE_PATH, PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN, } from "../../../html/hydration-script-builder/prod-scripts.js";
3
3
  import { computeStrongEtag, hasMatchingEtag } from "../utils/etag.js";
4
4
  import { HTTP_OK, PRIORITY_HIGH_DEV } from "../../../utils/constants/index.js";
5
5
  let cachedModule = null;
@@ -20,6 +20,8 @@ export class ProdHydrationModuleHandler extends BaseHandler {
20
20
  patterns: [
21
21
  { pattern: PROD_HYDRATION_MODULE_PATH, exact: true, method: "GET" },
22
22
  { pattern: PROD_HYDRATION_MODULE_PATH, exact: true, method: "HEAD" },
23
+ { pattern: PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN, method: "GET" },
24
+ { pattern: PROD_HYDRATION_MODULE_VERSIONED_PATH_PATTERN, method: "HEAD" },
23
25
  ],
24
26
  };
25
27
  async handle(req, ctx) {
@@ -27,14 +29,19 @@ export class ProdHydrationModuleHandler extends BaseHandler {
27
29
  return this.continue();
28
30
  }
29
31
  const method = req.method.toUpperCase();
32
+ const pathname = new URL(req.url).pathname;
33
+ const cacheStrategy = isVersionedProdHydrationModulePath(pathname) ? "immutable" : "no-cache";
30
34
  const { js, etag } = getProdHydrationModuleBundle();
31
35
  const builder = this.createResponseBuilder(ctx).withCORS(req, ctx.securityConfig?.cors);
32
36
  if (hasMatchingEtag(req, etag)) {
33
- return this.respond(builder.withSecurity(ctx.securityConfig ?? undefined, req).notModified(etag));
37
+ return this.respond(builder
38
+ .withSecurity(ctx.securityConfig ?? undefined, req)
39
+ .withCache(cacheStrategy)
40
+ .notModified(etag));
34
41
  }
35
42
  return this.respond(builder
36
43
  .withSecurity(ctx.securityConfig ?? undefined, req)
37
- .withCache("no-cache")
44
+ .withCache(cacheStrategy)
38
45
  .withETag(etag)
39
46
  .withContentType("application/javascript; charset=utf-8", method === "HEAD" ? null : js, HTTP_OK));
40
47
  }
@@ -1 +1 @@
1
- {"version":3,"file":"static.handler.d.ts","sourceRoot":"","sources":["../../../../../src/src/server/handlers/request/static.handler.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAmB,aAAa,EAAE,MAAM,aAAa,CAAC;AAkCnG,qBAAa,aAAc,SAAQ,WAAW;IAC5C,QAAQ,EAAE,eAAe,CAOvB;IAEF,OAAO,CAAC,aAAa,CAA2B;IAEhD,MAAM,CAAC,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC;IAejE,OAAO,CAAC,cAAc;CAwEvB"}
1
+ {"version":3,"file":"static.handler.d.ts","sourceRoot":"","sources":["../../../../../src/src/server/handlers/request/static.handler.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAmB,aAAa,EAAE,MAAM,aAAa,CAAC;AAoCnG,qBAAa,aAAc,SAAQ,WAAW;IAC5C,QAAQ,EAAE,eAAe,CAOvB;IAEF,OAAO,CAAC,aAAa,CAA2B;IAEhD,MAAM,CAAC,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC;IAejE,OAAO,CAAC,cAAc;CAwEvB"}
@@ -15,6 +15,7 @@ import { withSpan } from "../../../observability/tracing/otlp-setup.js";
15
15
  import { StaticFileService } from "../../services/static/index.js";
16
16
  import { addNonceToHtmlTags } from "../../../html/nonce-injection.js";
17
17
  import { computeEtag } from "../utils/etag.js";
18
+ import { isVersionedProdHydrationModulePath } from "../../../html/hydration-script-builder/prod-scripts.js";
18
19
  function isHtmlResponse(contentType) {
19
20
  return /\btext\/html\b/i.test(contentType);
20
21
  }
@@ -24,6 +25,7 @@ function isProductionBuildAssetPath(pathname) {
24
25
  pathname === "/_veryfront/router.js" ||
25
26
  pathname === "/_veryfront/prefetch.js" ||
26
27
  pathname === "/_veryfront/hydration-runtime.js" ||
28
+ isVersionedProdHydrationModulePath(pathname) ||
27
29
  pathname === "/_veryfront/manifest.json" ||
28
30
  pathname.startsWith("/_veryfront/chunks/") ||
29
31
  pathname.startsWith("/_veryfront/pages/") ||
@@ -50,7 +50,7 @@ export const LIGHTWEIGHT_PATH_PREFIXES = [
50
50
  "/_vf_modules/",
51
51
  "/_vf_styles/",
52
52
  "/_veryfront/modules/",
53
- "/_veryfront/hydration-runtime.js",
53
+ "/_veryfront/hydration-runtime",
54
54
  "/_veryfront/preview-hmr.js",
55
55
  "/_veryfront/studio-bridge.js",
56
56
  "/_vf/css/",
@@ -1,3 +1,3 @@
1
1
  /** Shared version value. */
2
- export declare const VERSION = "0.1.825";
2
+ export declare const VERSION = "0.1.827";
3
3
  //# sourceMappingURL=version-constant.d.ts.map
@@ -1,4 +1,4 @@
1
1
  // Keep in sync with deno.json version.
2
2
  // scripts/release.ts updates this constant during releases.
3
3
  /** Shared version value. */
4
- export const VERSION = "0.1.825";
4
+ export const VERSION = "0.1.827";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "veryfront",
3
- "version": "0.1.825",
3
+ "version": "0.1.827",
4
4
  "description": "The simplest way to build AI-powered apps",
5
5
  "keywords": [
6
6
  "react",