Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
215 changes: 110 additions & 105 deletions Cargo.lock

Large diffs are not rendered by default.

34 changes: 17 additions & 17 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ indexmap = "2.9.0"
indoc = "2.0.5"
infer = "0.19.0"
insta = "1.43.1"
itertools = "0.14.0"
itertools = "0.15.0"
itoa = "1.0.15"
json-escape-simd = "3"
json-strip-comments = "3"
Expand Down Expand Up @@ -247,7 +247,7 @@ pnp = "0.12.9"
percent-encoding = "2.3.1"
petgraph = "0.8.2"
pretty_assertions = "1.4.1"
phf = "0.13.0"
phf = { version = "0.14.0", features = ["macros"] }
prettyplease = "0.2.32"
proc-macro2 = "1"
pty_terminal_test = { git = "https://github.com/voidzero-dev/vite-task.git", rev = "4003f65a3e5e3d957ff81b157e85e6ee41cc59fc" }
Expand Down Expand Up @@ -276,7 +276,7 @@ simdutf8 = "0.1.5"
smallvec = { version = "1.15.1", features = ["union"] }
snapshot_test = { git = "https://github.com/voidzero-dev/vite-task.git", rev = "4003f65a3e5e3d957ff81b157e85e6ee41cc59fc" }
string_cache = "0.9.0"
sugar_path = { version = "2.0.1", features = ["cached_current_dir"] }
sugar_path = { version = "3", features = ["cached_current_dir"] }
supports-color = "3"
syn = { version = "2", default-features = false }
tar = "0.4.43"
Expand Down Expand Up @@ -317,7 +317,7 @@ xxhash-rust = "0.8.15"
zip = { version = "7.2", default-features = false, features = ["deflate-flate2-zlib-rs"] }

# oxc crates with the same version
oxc = { version = "0.139.0", features = [
oxc = { version = "0.140.0", features = [
"ast_visit",
"transformer",
"minifier",
Expand All @@ -329,22 +329,22 @@ oxc = { version = "0.139.0", features = [
"regular_expression",
"cfg",
] }
oxc_allocator = { version = "0.139.0", features = ["pool"] }
oxc_ast = "0.139.0"
oxc_ecmascript = "0.139.0"
oxc_parser = "0.139.0"
oxc_span = "0.139.0"
oxc_napi = "0.139.0"
oxc_str = "0.139.0"
oxc_minify_napi = "0.139.0"
oxc_parser_napi = "0.139.0"
oxc_transform_napi = "0.139.0"
oxc_traverse = "0.139.0"
oxc_allocator = { version = "0.140.0", features = ["pool"] }
oxc_ast = "0.140.0"
oxc_ecmascript = "0.140.0"
oxc_parser = "0.140.0"
oxc_span = "0.140.0"
oxc_napi = "0.140.0"
oxc_str = "0.140.0"
oxc_minify_napi = "0.140.0"
oxc_parser_napi = "0.140.0"
oxc_transform_napi = "0.140.0"
oxc_traverse = "0.140.0"

# oxc crates in their own repos
oxc_index = { version = "5", features = ["rayon", "serde"] }
oxc_resolver = { version = "11.23.0", features = ["yarn_pnp"] }
oxc_resolver_napi = { version = "11.23.0", default-features = false, features = ["yarn_pnp"] }
oxc_resolver = { version = "11.24.2", features = ["yarn_pnp"] }
oxc_resolver_napi = { version = "11.24.2", default-features = false, features = ["yarn_pnp"] }
oxc_sourcemap = "8.1.0"

# rolldown crates
Expand Down
43 changes: 27 additions & 16 deletions packages/cli/binding/index.d.cts
Original file line number Diff line number Diff line change
Expand Up @@ -1631,11 +1631,16 @@ export declare class BindingDevEngine {
getBundleState(): Promise<BindingBundleState>;
ensureLatestBuildOutput(): Promise<BindingResult<undefined>>;
triggerFullBuild(): void;
invalidate(
caller: string,
firstInvalidatedBy?: string | undefined | null,
): Promise<BindingResult<Array<BindingClientHmrUpdate>>>;
registerModules(clientId: string, modules: Array<string>): Promise<void>;
/**
* Client-connect signal (the clientId hello): creates the per-client session
* with an empty ship map. Reconnects arrive as fresh clientIds.
*/
registerClient(clientId: string): Promise<void>;
/**
* Delivery notification from the serving middleware: the response for
* `filename` completed, so record its modules as shipped to that client.
*/
notifyPayloadDelivered(filename: string): Promise<void>;
removeClient(clientId: string): Promise<void>;
close(): Promise<void>;
/**
Expand All @@ -1645,7 +1650,7 @@ export declare class BindingDevEngine {
* The module was previously stubbed with a proxy, and now we need to compile the
* actual module and its dependencies.
*/
compileEntry(moduleId: string, clientId: string): Promise<string>;
compileEntry(moduleId: string, clientId: string): Promise<BindingLazyChunkOutput>;
}

export declare class BindingLoadPluginContext {
Expand Down Expand Up @@ -2355,19 +2360,18 @@ export interface BindingGeneratedCodeOptions {
preset?: string;
}

export interface BindingHmrBoundaryOutput {
boundary: string;
acceptedVia: string;
}

export type BindingHmrUpdate =
| {
type: 'Patch';
code: string;
filename: string;
sourcemap?: string;
sourcemapFilename?: string;
hmrBoundaries: Array<BindingHmrBoundaryOutput>;
sourcemapFilename?: string /**
* Stable ids of the changed modules — the `changedIds` of the push envelope.
* The client walks from these on its own graph.
*/;
changedIds: Array<string> /** Per-client envelope sequence number. */;
seq: number;
}
| { type: 'FullReload'; reason?: string }
| { type: 'Noop' };
Expand Down Expand Up @@ -2538,6 +2542,15 @@ export interface BindingJsWatchChangeEvent {
event: string;
}

/**
* The client-facing slice of a lazy-compile result. The carried modules and
* stamps stay server-side as the engine's pending-payload entry.
*/
export interface BindingLazyChunkOutput {
code: string;
filename: string;
}

export interface BindingLog {
message: string;
id?: string;
Expand Down Expand Up @@ -2843,8 +2856,7 @@ export declare const enum BindingPropertyWriteSideEffects {

export declare const enum BindingRebuildStrategy {
Always = 0,
Auto = 1,
Never = 2,
Never = 1,
}

export interface BindingReplacePluginConfig {
Expand Down Expand Up @@ -3189,7 +3201,6 @@ export interface JsOutputChunk {
map?: BindingSourcemap;
sourcemapFilename?: string;
preliminaryFilename: string;
preliminarySourcemapFilename?: string;
}

/** Error emitted from native side, it only contains kind and message, no stack trace. */
Expand Down
13 changes: 11 additions & 2 deletions packages/core/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,16 @@ async function wireBundledTsdownExtensions() {
content = content.replaceAll('import("@tsdown/css")', 'import("./tsdown-css.js")');
changed = true;
}
if (content.includes('import("./tsdown-css.js")')) {
// The css plugin ends up loading from a bundled sibling chunk in one of two
// ways: either the rewrite above pointed it at `./tsdown-css.js`, or rolldown
// already deduped the static `import("@tsdown/css")` into its own shared chunk
// (e.g. `const { CssPlugin } = await import("./dist-<hash>.js")`). Either way
// `@tsdown/css` stays inside the bundle; only a bare specifier that escapes to
// the top-level package would be a miss.
if (
content.includes('import("./tsdown-css.js")') ||
/\bCssPlugin\b[^\n]*await import\((["'])\.\/[^"']+\1\)/.test(content)
) {
cssLoadWired = true;
}
if (changed) {
Expand All @@ -667,7 +676,7 @@ async function wireBundledTsdownExtensions() {
throw new Error('wireBundledTsdownExtensions: `pkgExists("@tsdown/css")` not found');
}
if (!cssLoadWired) {
throw new Error('wireBundledTsdownExtensions: bundled `./tsdown-css.js` is never imported');
throw new Error('wireBundledTsdownExtensions: bundled `@tsdown/css` is never imported');
}
}

Expand Down
8 changes: 4 additions & 4 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@
"@oxc-node/core": "catalog:",
"@tsdown/css": "catalog:",
"@tsdown/exe": "catalog:",
"@vitejs/devtools": "^0.4.0",
"@vitejs/devtools": "^0.4.1",
"es-module-lexer": "^1.7.0",
"hookable": "^6.0.1",
"magic-string": "^0.30.21",
Expand Down Expand Up @@ -214,8 +214,8 @@
"node": "^20.19.0 || ^22.18.0 || >=24.11.0"
},
"bundledVersions": {
"vite": "8.1.4",
"rolldown": "1.1.5",
"tsdown": "0.22.7"
"vite": "8.1.5",
"rolldown": "1.2.0",
"tsdown": "0.22.9"
}
}
4 changes: 2 additions & 2 deletions packages/tools/.upstream-versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
"rolldown": {
"repo": "https://github.com/rolldown/rolldown.git",
"branch": "main",
"hash": "f09947ab017d6df74299f691853dcfc4f4f0f86e"
"hash": "03e1e3422cd85495c9863ff3bc3b24212d9f4be2"
},
"vite": {
"repo": "https://github.com/vitejs/vite.git",
"branch": "main",
"hash": "a477454442eff649b430f9e3c6caf2500fcb7183"
"hash": "5e7fe129a4dde4f41934083b25e490059985f4e6"
}
}
Loading
Loading