-
Notifications
You must be signed in to change notification settings - Fork 710
Description
Problem
Several native Vite-related plugins inside Rolldown (e.g. HTML, CSS, asset plugins) currently rely on inputOptions.cwd when resolving paths or determining the project root.
However, in Vite’s semantics, root is the actual project root — used for locating index.html, resolving public files, determining the dev-server base directory, and defining the allowed filesystem scope.
When: process.cwd() !== viteConfig.root (which is very common in monorepos), these plugins may behave inconsistently compared to vite build, producing incorrect path resolution.
Future Direction
After this change, we can consider (if safe):
Allowing_ rolldown-vite to pass
viteConfig.rootascwdto Rolldown.
But this requires further evaluation because bundler-level cwd affects import resolution.