Skip to content

charlie: next/v3 core correctness parity with main (compile, preview, config) #350

Description

@charliecreates

Subtask of #348. Align next/v3 core correctness with main by porting the compile path resolution, preview deploy --build-path semantics (including relative paths and bundling react/jsx-runtime), and config module import/file URL handling, while keeping Node/React version ranges as defined on next/v3.

Target branch

All work for this issue should be implemented against the next/v3 branch.

  • Branch from origin/next/v3.
  • Open pull requests with base set to next/v3 (not main).
  • Keep next/v3's Node/React version ranges and other v3-specific tooling in place.

Context

next/v3 already contains v3-specific CLI and tooling changes, but it's missing several correctness fixes that have shipped on main since the branches diverged. This issue focuses on bringing over the "core correctness" pieces without changing the v3 product shape:

  • Compile output paths: align compile behavior so compiled templates and .meta.json files land in the same locations as they do on main, including cross-platform behavior.
  • Preview deploy paths: align the email preview --build-path behavior so next/v3 supports relative --build-path values and uses the same default path semantics as main, while still targeting the v3 preview app.
  • Config module loading: align config loading (including file:// URL handling and Windows-safe dynamic import behavior) so next/v3 sees the same config files as main in the same situations.

Implementation notes

When working this issue:

  1. Use the comparison work in charlie: head vs next/v3 #348 as the source of truth for what "correct" looks like on main.
  2. Prefer porting the relevant implementations and tests from main into next/v3 wholesale, then reconciling any v3-specific differences, instead of rewriting behavior from scratch.
  3. Add or update tests on next/v3 so that these behaviors are covered directly; aim for the same test intent and coverage main has for compile paths, preview deploy paths, and config loading.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions