Skip to content

feat: add vite-plus support#7128

Open
serhalp wants to merge 3 commits into
mainfrom
serhalp/feat/vite-plus-build-system
Open

feat: add vite-plus support#7128
serhalp wants to merge 3 commits into
mainfrom
serhalp/feat/vite-plus-build-system

Conversation

@serhalp

@serhalp serhalp commented Jul 15, 2026

Copy link
Copy Markdown
Member

Summary

https://viteplus.dev doesn't quite fit into the boxes we currently use in this package, since it's a sort of package manager wrapper, a monorepo/build tool, and it even has vp build and vp dev.

But I believe I've found a reasonable way to get this all working without any hacks. By just registering it as a new "build system" and extending the vite "framework" with a bit of vite-plus knowledge:

  • It's detected. We need this to show a pretty logo, capture usage in telemetry, and to run vp install automatically in our build system.
  • The monorepo tooling should just work. This is used by Netlify CLI's netlify dev --filter foo to construct the right underlying vp command.
  • When vite-plus is installed (but no vite-based metaframework), we'll default to vp build and vp dev instead of vite build and vite dev.

Closes #7013

https://viteplus.dev doesn't quite fit into the boxes we currently use in this package, since it's
a sort of package manager wrapper, a monorepo/build tool, and it even has `vp build` and `vp dev`.

But it seems we can get most of this working by just registering it as a "build system":
- It's detected. We need this to show a pretty logo, capture usage in telemetry, and to run `vp
  install` automatically in our build system.
- The monorepo tooling should just work. This is used by Netlify CLI's `netlify dev --filter foo` to
  construct the right underlying `vp` command.
@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 1baaa9ea-afe5-4add-9c13-c65b86daf951

📥 Commits

Reviewing files that changed from the base of the PR and between e6f1c75 and d563c7a.

📒 Files selected for processing (2)
  • packages/build-info/src/build-systems/vite-plus.test.ts
  • packages/build-info/src/build-systems/vite-plus.ts
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • netlify/blueprints (manual)
🚧 Files skipped from review as they are similar to previous changes (2)
  • packages/build-info/src/build-systems/vite-plus.ts
  • packages/build-info/src/build-systems/vite-plus.test.ts

📝 Walkthrough

Summary by CodeRabbit

  • New Features

    • Added support for detecting Vite Plus projects.
    • Added Vite Plus commands for development, builds, and workspace scripts.
    • Vite projects using Vite Plus now use the vp dev and vp build commands.
    • Added support for resolving Vite Plus versions from npm, pnpm, and Yarn lockfiles.
  • Bug Fixes

    • Improved detection in monorepos and projects with nested lockfiles.

Walkthrough

Adds Vite Plus as a supported build system with dependency detection, exact version resolution from npm, pnpm, and Yarn lockfiles, workspace command generation, and fallback handling. Registers the new build system and adds tests for detection and commands. Extends Vite framework detection to use vp dev and vp build when Vite Plus is present, with tests for precedence and framework exclusions.

Estimated code review effort: 3 (Moderate) | ~25 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately summarizes the main change: adding Vite+ support.
Description check ✅ Passed The description explains the motivation and links the issue, but it omits some template checklist items and uses 'Closes' instead of 'Fixes'.
Linked Issues check ✅ Passed The changes add Vite+ build-system detection and Vite framework integration, matching the linked issue's goal.
Out of Scope Changes check ✅ Passed The added dependency, tests, and framework/build-system updates are all directly related to Vite+ support.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch serhalp/feat/vite-plus-build-system

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

e18e dependency analysis

No dependency warnings found.

@serhalp serhalp marked this pull request as ready for review July 15, 2026 14:41
@serhalp serhalp requested a review from a team as a code owner July 15, 2026 14:41

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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/build-info/src/build-systems/vite-plus.ts`:
- Around line 56-95: Update detect() and resolveLockedVersion() so lockfile
discovery starts from the directory containing the package.json that declared
vite-plus, rather than always from project.baseDirectory. Pass the declaring
manifest path or its directory from detect() into resolveLockedVersion(), and
use it as the findUp() cwd while preserving the existing root boundary and
version fallback behavior.
🪄 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: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 8cbda9f2-0580-498f-bc24-7cd408fa71ce

📥 Commits

Reviewing files that changed from the base of the PR and between 46836e0 and e6f1c75.

⛔ Files ignored due to path filters (3)
  • package-lock.json is excluded by !**/package-lock.json
  • packages/build-info/assets/logos/vite-plus/icon-color-dark.svg is excluded by !**/*.svg
  • packages/build-info/assets/logos/vite-plus/icon-color-light.svg is excluded by !**/*.svg
📒 Files selected for processing (6)
  • packages/build-info/package.json
  • packages/build-info/src/build-systems/index.ts
  • packages/build-info/src/build-systems/vite-plus.test.ts
  • packages/build-info/src/build-systems/vite-plus.ts
  • packages/build-info/src/frameworks/vite.test.ts
  • packages/build-info/src/frameworks/vite.ts
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • netlify/blueprints (manual)

Comment thread packages/build-info/src/build-systems/vite-plus.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Vite+ Global CLI Support

2 participants