Staging, 2026-11-18. Pulled forward from "after the cut". @tobiu that night, on what to push for Engine 14: "especially the "webpack removal" => own webserver with HTTP/3 support parts", and "the date november 23 is set; the scope is not." The numbers below decide both halves of that sentence. The harness (the script, the workflow, the table) is @neo-gemini-maryam's since 2026-11-18 (branch agent/21216-measure-esm-vs-bundled); the assignment moved to her with her claim. The closing paragraph of the criteria is @neo-fable-mnemosyne's to write from the table, unless the builder wants it. 2026-11-18, 06:16Z: the table and a Decision paragraph by the builder are in comment 6970782221. Two findings on what its cells can carry, and a row 4b′ that the paragraph's retirement of 4b has to meet, are in Discussion 21311, comment 19702807. That Discussion is the follow-up the last criterion asks for.
Context
The source Discussion (https://github.com/orgs/neomjs/discussions/21210, closed) deferred its fourth axis, what builds the bundled environments, until one measurement exists (its OQ-6). @tobiu's inputs on 2026-11-17: general bundlers spend their weight on TypeScript compilation and hot module replacement, which the engine uses neither of; removing webpack is a goal for the dependency tree; "an own bundler could be in v14.1. depends on how fast our team makes progress"; and later the same hour, "if our team is fast, it MIGHT happen for v14, but v14.1 is fine too."
What webpack costs today: its four packages keep 211 of the engine's 560 lockfile entries installed, buildScripts/webpack/ is 13 files with three custom plugins (282 lines), and src carries 45 webpack magic comments. The dev server's share of that leaves with #21215.
The Problem
Nobody has measured what dist/development and dist/production give a deployed app that dist/esm does not. Two things are known:
The generated starter app on localhost, one run per environment: the bundled builds load 16 JS files, dist/esm and dev mode 167, and the welcome text is visible after 0.20 to 0.22 s in all four. Localhost hides what a network does to 167 requests.
The live site cannot answer it. On 2026-11-17 every environment URL of the portal I loaded, on neomjs.com and on the Pages origin, came up as dist/production.
Without the number, the choice between no bundler at all, esbuild, a bundler of our own and keeping webpack is taste.
The Architectural Reality
buildScripts/build/esmodules.mjs builds dist/esm without webpack: Terser compresses and mangles each module, on a plan from createEsmBuildPlan (buildScripts/util/esmBuildGraph.mjs:39). The plan returns {files, excludedOutputs} and leaves dynamic imports to their runtime admission. It computes no entry manifests for workers, addons, canvas modules or apps.
buildScripts/webpack/buildThreads.mjs builds one bundle per thread for dist/development and dist/production, with canvasModuleContextPlugin.mjs, mainAddonContextPlugin.mjs, workerContextRebasePlugin.mjs and loader/template-loader.mjs. The magic comments in src (webpackInclude 8, webpackExclude 13, webpackMode 13, webpackIgnore 11) express context imports.
buildScripts/util/check-consumer-runtime-build.mjs is the prior art for proving that a consumer build selects the right modules.
Two claims from the Discussion that this measurement tests and does not assume: a modulepreload link does not cover a worker's static import chain, which runs eight to twelve modules deep (Julia); and esbuild's documentation records an import-order limit for code splitting, which could break class registration or singleton identity across lazy chunks (Euclid).
Design authority: n/a — a measurement; it calls no existing behavior wrong.
The rows it decides between, as the Discussion left them:
Row
Shape
4a
keep webpack, installed only when a bundled build runs
4b
retire both bundled environments; dist/esm is the deployment
4d′
esbuild with code splitting, on a manifest and admission layer that does not exist yet
4e
a bundler of the engine's own on the ESM build graph
The Fix
A measurement script, and its result in this ticket:
Build the portal and one generated starter app from a single commit in dist/esm and in dist/production.
Serve both over HTTP/2 and over HTTP/3, on a link with added round-trip latency: none, 50 ms and 150 ms. One further arm adds packet loss (1 % at 50 ms): HTTP/2 multiplexes its streams over one TCP connection, where a lost packet holds all of them, and HTTP/3 does not. On a clean link the two are expected to read alike, so without this arm the table cannot show what HTTP/3 is for. HTTP/3 is the arm dist/esm was designed for (@tobiu, 2026-11-17: "dist/esm excels with HTTP3 => sending many small files in parallel").
What serves it. Node cannot yet. node:quic stands at stability 1.0, "Early development", behind --experimental-quic (the v26.11.0 documentation, read 2026-11-18), and Node 25.9 does not ship the module (ERR_UNKNOWN_BUILTIN_MODULE with the flag set, same day). The engine's floor is Node 24. So the measurement uses one reference server that speaks HTTP/2 and HTTP/3 from the same files; which one is the builder's choice.
Where. A hosted Linux runner, so that latency and loss are applied to the link itself and one command reproduces the table.
Proof of the arm. Every run reports the protocol each request used (nextHopProtocol of its resource timing entry). A cell counts for HTTP/3 only if its requests say h3.
How the browser comes to trust the certificate and to use HTTP/3 on a first connection is part of the work.
For each build and latency, cold cache and warm cache, five runs: the time to a meaningful frame (the portal's home view fully laid out; the starter's welcome text), the request count, the transferred bytes, and the app worker's import waterfall (depth and elapsed time).
After the frame: one interaction and one lazy extension (a route or component that loads a lazily imported module), each timed.
A third arm, an esbuild build of the app worker with splitting: true from a hand-written entry list, measured the same way and checked for class registration and singleton identity across chunks. It is a probe for row 4d′, not its implementation.
The script's placement is the implementer's, per structural-pre-flight.
Acceptance Criteria
One command reproduces the table from a clean checkout; it names the commit, the machine, the browser build and the run count.
The table has every cell of points 2 to 4 for dist/esm and dist/production, with the spread of the five runs beside each median and the protocol its requests reported.
The worker's import waterfall is reported with its depth, so the modulepreload claim is confirmed or dropped.
The esbuild arm is reported, or the reason it could not be built is, with the failing import named.
The ticket ends with one paragraph that names which of rows 4a, 4b, 4d′ and 4e the numbers leave standing, and why.
The same paragraph says in which cells HTTP/3 differs from HTTP/2 and what that means for the engine's own server (#21215): a TLS listener with HTTP/2, HTTP/3 as well once Node's module leaves its flag, or neither.
A follow-up is filed for the surviving row or rows; if it changes the bundler, it names its window: 14.0 if the team gets there, otherwise 14.1.
Out of Scope
Changing a build. This ticket produces numbers and a paragraph.
The dev server (#21215) and the first-run rows (#21213).
Plain CSS in place of SCSS (Discussion 18182).
Avoided Traps
Timing on localhost alone. It hides the waterfall this ticket exists to see.
An HTTP/1.1 server. Six connections per origin distort a comparison of 16 files against 167. Leaving HTTP/3 out would distort it the other way: it is the protocol dist/esm counts on.
Reading the live site. It serves dist/production at every environment URL.
A latency added in the response handler or in the browser. It is not a link: connection setup and loss recovery stay free, and those are where the two protocols differ.
Comparing the protocols on a clean link only. They are expected to read alike there; the loss arm is where they can part.
A threshold chosen before the numbers. The paragraph argues from what was measured.
Live latest-open + closed sweep: checked latest 20 open + open and closed search ("dist/esm", "bundler", "esbuild splitting", "dist/production webpack"; the closed dist/esm correctness tickets #20964, #20978, #20963 and #20863 read by title, they fix admission and do not measure) at 2026-11-17T04:21Z; no equivalent or prior exclusion found. Backlog band: 87 open, red; #21213 scopes this axis out and no other ticket or epic owns it, so it is filed.
MC sweep: "webpack dev server only serves static files; replace webpack with esbuild or own bundler; dist/development not needed for dev mode", 6 results, no prior decision.
Own-assignment sweep: 4 open, none overlapping.
A2A sweep: latest 8 messages, no claim on this scope.
Origin Session ID: b3758981-efde-4777-921c-8c57fe3a804e
Retrieval Hint: "dist/esm versus dist/production measurement bundler choice esbuild splitting own bundler 14.1"
No curated labels: its result decides a design.
Staging, 2026-11-18. Pulled forward from "after the cut". @tobiu that night, on what to push for Engine 14: "especially the "webpack removal" => own webserver with HTTP/3 support parts", and "the date november 23 is set; the scope is not." The numbers below decide both halves of that sentence. The harness (the script, the workflow, the table) is @neo-gemini-maryam's since 2026-11-18 (branch
agent/21216-measure-esm-vs-bundled); the assignment moved to her with her claim. The closing paragraph of the criteria is @neo-fable-mnemosyne's to write from the table, unless the builder wants it. 2026-11-18, 06:16Z: the table and a Decision paragraph by the builder are in comment 6970782221. Two findings on what its cells can carry, and a row4b′that the paragraph's retirement of4bhas to meet, are in Discussion 21311, comment 19702807. That Discussion is the follow-up the last criterion asks for.Context
The source Discussion (https://github.com/orgs/neomjs/discussions/21210, closed) deferred its fourth axis, what builds the bundled environments, until one measurement exists (its OQ-6). @tobiu's inputs on 2026-11-17: general bundlers spend their weight on TypeScript compilation and hot module replacement, which the engine uses neither of; removing webpack is a goal for the dependency tree; "an own bundler could be in v14.1. depends on how fast our team makes progress"; and later the same hour, "if our team is fast, it MIGHT happen for v14, but v14.1 is fine too."
What webpack costs today: its four packages keep 211 of the engine's 560 lockfile entries installed,
buildScripts/webpack/is 13 files with three custom plugins (282 lines), andsrccarries 45 webpack magic comments. The dev server's share of that leaves with #21215.The Problem
Nobody has measured what
dist/developmentanddist/productiongive a deployed app thatdist/esmdoes not. Two things are known:dist/esmand dev mode 167, and the welcome text is visible after 0.20 to 0.22 s in all four. Localhost hides what a network does to 167 requests.dist/production.Without the number, the choice between no bundler at all, esbuild, a bundler of our own and keeping webpack is taste.
The Architectural Reality
buildScripts/build/esmodules.mjsbuildsdist/esmwithout webpack: Terser compresses and mangles each module, on a plan fromcreateEsmBuildPlan(buildScripts/util/esmBuildGraph.mjs:39). The plan returns{files, excludedOutputs}and leaves dynamic imports to their runtime admission. It computes no entry manifests for workers, addons, canvas modules or apps.buildScripts/webpack/buildThreads.mjsbuilds one bundle per thread fordist/developmentanddist/production, withcanvasModuleContextPlugin.mjs,mainAddonContextPlugin.mjs,workerContextRebasePlugin.mjsandloader/template-loader.mjs. The magic comments insrc(webpackInclude8,webpackExclude13,webpackMode13,webpackIgnore11) express context imports.buildScripts/util/check-consumer-runtime-build.mjsis the prior art for proving that a consumer build selects the right modules.modulepreloadlink does not cover a worker's static import chain, which runs eight to twelve modules deep (Julia); and esbuild's documentation records an import-order limit for code splitting, which could break class registration or singleton identity across lazy chunks (Euclid).Design authority: n/a — a measurement; it calls no existing behavior wrong.The rows it decides between, as the Discussion left them:
dist/esmis the deploymentThe Fix
A measurement script, and its result in this ticket:
dist/esmand indist/production.dist/esmwas designed for (@tobiu, 2026-11-17: "dist/esm excels with HTTP3 => sending many small files in parallel").node:quicstands at stability 1.0, "Early development", behind--experimental-quic(the v26.11.0 documentation, read 2026-11-18), and Node 25.9 does not ship the module (ERR_UNKNOWN_BUILTIN_MODULEwith the flag set, same day). The engine's floor is Node 24. So the measurement uses one reference server that speaks HTTP/2 and HTTP/3 from the same files; which one is the builder's choice.nextHopProtocolof its resource timing entry). A cell counts for HTTP/3 only if its requests sayh3.splitting: truefrom a hand-written entry list, measured the same way and checked for class registration and singleton identity across chunks. It is a probe for row 4d′, not its implementation.The script's placement is the implementer's, per
structural-pre-flight.Acceptance Criteria
dist/esmanddist/production, with the spread of the five runs beside each median and the protocol its requests reported.modulepreloadclaim is confirmed or dropped.Out of Scope
Avoided Traps
dist/esmcounts on.dist/productionat every environment URL.Related
Live latest-open + closed sweep: checked latest 20 open + open and closed search ("dist/esm", "bundler", "esbuild splitting", "dist/production webpack"; the closed
dist/esmcorrectness tickets#20964,#20978,#20963and#20863read by title, they fix admission and do not measure) at 2026-11-17T04:21Z; no equivalent or prior exclusion found. Backlog band: 87 open, red; #21213 scopes this axis out and no other ticket or epic owns it, so it is filed. MC sweep: "webpack dev server only serves static files; replace webpack with esbuild or own bundler; dist/development not needed for dev mode", 6 results, no prior decision. Own-assignment sweep: 4 open, none overlapping. A2A sweep: latest 8 messages, no claim on this scope.Origin Session ID: b3758981-efde-4777-921c-8c57fe3a804e Retrieval Hint: "dist/esm versus dist/production measurement bundler choice esbuild splitting own bundler 14.1"