Repository navigation
feat(schema): enable nitro vite environment by default in v5 - #35891
Conversation
@nuxt/kit
@nuxt/nitro-server
nuxt
@nuxt/rspack-builder
@nuxt/schema
@nuxt/vite-builder
@nuxt/webpack-builder
commit: |
30dcffa to
c359b1e
Compare
c359b1e to
26fbcbc
Compare
26fbcbc to
711e1c0
Compare
711e1c0 to
22f5907
Compare
22f5907 to
1cfcfc1
Compare
1cfcfc1 to
fffb36f
Compare
fffb36f to
411ad18
Compare
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/schema/src/types/schema.ts`:
- Around line 1681-1684: Update the documentation for the compatibility-gated
option near `future.compatibilityVersion` to state that its default is `true`
for compatibility version 5 or higher and `false` for version 4 unless
explicitly enabled. Keep the existing behavior description and align the wording
with other compatibility-dependent options.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 5b294f60-b572-4cd7-bc03-94488b691b1d
📒 Files selected for processing (2)
packages/schema/src/config/experimental.tspackages/schema/src/types/schema.ts
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
vitest.config.ts (1)
134-137: 🩺 Stability & Availability | 🟠 Major | ⚡ Quick winReapply serialisation for
nitro-vitefixture matrix projects.The explicit Nuxt projects still use
defineVitestProject, which disablesexperimental.nitroViteEnvironment; the matrix entries fromfixtureMatrix.map(...)do not, and those entries includenitro-vite. WithfileParallelismno longer disabled, those two fixture matrix projects can build concurrently whilenitro/viteruns the full build and writes output, re-introducing shared fixture/state races. Include the serial builder override for the mapped fixture projects or add a per-projectfileParallelismsetting.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@vitest.config.ts` around lines 134 - 137, Update the fixture projects created by fixtureMatrix.map(...) to serialize builds for nitro-vite entries, either by applying the existing serial builder override or by setting fileParallelism per project. Preserve the current retry, benchmark, and fixtureProjectEnv configuration while preventing concurrent shared fixture/state writes.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In `@vitest.config.ts`:
- Around line 134-137: Update the fixture projects created by
fixtureMatrix.map(...) to serialize builds for nitro-vite entries, either by
applying the existing serial builder override or by setting fileParallelism per
project. Preserve the current retry, benchmark, and fixtureProjectEnv
configuration while preventing concurrent shared fixture/state writes.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 15295ebc-1b53-4f30-9b1b-eff42c53b4c6
📒 Files selected for processing (1)
vitest.config.ts
Merging this PR will degrade performance by 58.32%
|
| Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|
| ❌ | initial production build in the minimal test fixture |
1.4 s | 3.4 s | -58.32% |
Tip
Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.
Comparing feat/env-api-default (c06cdf8) with main (23ee6cf)
Footnotes
-
3 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩
dcc69cd to
9b23899
Compare
f4b501a to
2f8acb8
Compare
bdcb1e7 to
c06cdf8
Compare
|
LET'S GOOO 😆 |
🔗 Linked issue
📚 Description
this enables the
nitro/viteintegration with the vite environment api as the default for nuxt v5we may revert this before releasing v5 (cc: @pi0) but this enables us to test it more effectively beforehand