You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reviewed against the Vite source, rebased onto main (post 0.2.8), and fixed the findings in place. All fixes are amended into the original commit.
Root cause behind most findings: the extractor reads Vite's resolved config, where defaults are indistinguishable from user intent (resolveConfig fills optimizeDeps.noDiscovery: false, brace-form server.fs.deny, empty warmup arrays). Adoption is now gated on the raw user config where that matters.
Findings fixed:
noDiscovery default adopted as explicit. Every app without optimizeDeps would cross noDiscovery: false as a user setting. Now only crosses when the raw config sets a boolean.
Empty warmup arrays emitted. Vite's resolved default is { clientFiles: [], ssrFiles: [] }; we now emit only non-empty filtered lists.
warnUnsupported regressions. The narrowed warnings for optimizeDeps.esbuildOptions.plugins, rolldownOptions.plugins, and the rollupOptions spelling were dropped; restored.
warmup_paths matching. Patterns like ./src/*.tsx never matched (no ./ normalization), roots with glob metacharacters broke matching, and ! exclusions compared against absolute paths. Now: ./ stripped, root escaped with glob::Pattern::escape, exclusions matched root-relative (Vite's warmup.ts semantics).
fs.deny brace patterns. The glob crate has no brace expansion, so Vite's default-shaped **/{.git,node_modules}/** style deny entries silently matched nothing. Added recursive {a,b} expansion.
jsx translation.rolldownOptions.transform.jsx can be an object; esbuild's jsx option is string-only, so an object crossed as garbage. Only strings cross now (define/target/keepNames/drop unchanged).
noDiscovery missing from the optimizer cache key. Toggling it changed the run but not lockfile_hash, so a stale bundle survived the toggle. Shared effective_auto_discover now feeds both the run and the hash.
SSR warmup transform loop. Transforming ssrFiles inline duplicated work and ran before the hook plan existed; replaced with priming the SSR plugin host's hook plan when ssrFiles are present, so warmup goes through the gated path.
Also: the "settings survive actual config loading" test invoked vite-extract.mjs as a CLI, which no longer exists after the engine-job move; rewired to the extraction wrapper the rest of the suite uses. Added regression tests for 1, 4, 5, 6 (plus a real-vite test proving resolved defaults do not cross), and gave the e2e harness rmSync retries to fix an ENOTEMPTY cleanup race in the new vite-config-adoption e2e.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.