[orga-build] decouple vite root from content root#320
Merged
xiaoxinghu merged 5 commits intomainfrom Mar 1, 2026
Merged
Conversation
Adds an `exclude` array to orga-build config that accepts glob patterns, giving users a way to prevent specific files from being treated as pages or endpoints. Patterns are prefixed with `!` and appended to all three globby calls (routes, layouts, components). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Vite's root now defaults to process.cwd() instead of config.root. This decouples the content scanning directory from Vite's project root, allowing tools like the Cloudflare plugin to generate files at the project root rather than inside the content directory. Style URLs (e.g. '/style.css') are automatically prefixed with the relative path to the content root so they resolve correctly under the new Vite root without any changes to user config. BREAKING CHANGE: Vite plugins that rely on config.root internally will now see cwd instead of the content directory. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Style values are now treated as file paths relative to the config file (cwd), matching the convention of other config options like `root`. A leading slash is tolerated as an alternative spelling — both 'docs/style.css' and '/docs/style.css' resolve to the same URL. Normalization happens in loadConfig, removing the need for any transformation at plugin setup time. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
🦋 Changeset detectedLatest commit: de18ff6 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.