Skip to content

Build: Remove vite-plus as devDependency#34550

Merged
huang-julien merged 2 commits into
nextfrom
fix/vite-plus-devdepsoxfmt
Apr 15, 2026
Merged

Build: Remove vite-plus as devDependency#34550
huang-julien merged 2 commits into
nextfrom
fix/vite-plus-devdepsoxfmt

Conversation

@huang-julien
Copy link
Copy Markdown
Contributor

@huang-julien huang-julien commented Apr 15, 2026

Closes #34548

What I did

Vite plus as a dev deps was overriding the oxfmt package by injecting the vendored one.

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

  • stories
  • unit tests
  • integration tests
  • end-to-end tests

Manual testing


Caution

This section is mandatory for all contributions. If you believe no manual test is necessary, please state so explicitly. Thanks!

Documentation

  • Add or update documentation reflecting your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Checklist for Maintainers

  • When this PR is ready for testing, make sure to add ci:normal, ci:merged or ci:daily GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found in code/lib/cli-storybook/src/sandbox-templates.ts

  • Make sure this PR contains one of the labels below:

    Available labels
    • bug: Internal changes that fixes incorrect behavior.
    • maintenance: User-facing maintenance tasks.
    • dependencies: Upgrading (sometimes downgrading) dependencies.
    • build: Internal-facing build tooling & test updates. Will not show up in release changelog.
    • cleanup: Minor cleanup style change. Will not show up in release changelog.
    • documentation: Documentation only changes. Will not show up in release changelog.
    • feature request: Introducing a new feature.
    • BREAKING CHANGE: Changes that break compatibility in some way with current major version.
    • other: Changes that don't fit in the above categories.

🦋 Canary release

This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the @storybookjs/core team here.

core team members can create a canary release here or locally with gh workflow run --repo storybookjs/storybook publish.yml --field pr=<PR_NUMBER>

Summary by CodeRabbit

Release Notes

  • Chores
    • Transitioned vite-plus from a required dev dependency to an optional peer dependency, reducing unnecessary package installations
    • Updated code to gracefully handle optional peer dependency resolution

@huang-julien huang-julien requested a review from Sidnioulz April 15, 2026 10:49
@huang-julien huang-julien added patch:yes Bugfix & documentation PR that need to be picked to main branch build Internal-facing build tooling & test updates ci:normal labels Apr 15, 2026
@huang-julien huang-julien changed the title Build: remove vite-plus as devDependency Build: Remove vite-plus as devDependency Apr 15, 2026
@nx-cloud
Copy link
Copy Markdown

nx-cloud Bot commented Apr 15, 2026

View your CI Pipeline Execution ↗ for commit 7c14123

Command Status Duration Result
nx run-many -t compile,check,knip,test,lint,fmt... ✅ Succeeded 9m 24s View ↗

☁️ Nx Cloud last updated this comment at 2026-04-15 11:24:46 UTC

@huang-julien huang-julien marked this pull request as ready for review April 15, 2026 11:10
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 15, 2026

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: 1cab0c39-271c-43b7-8f5e-66830b208b2a

📥 Commits

Reviewing files that changed from the base of the PR and between a168d41 and 7c14123.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (2)
  • code/core/package.json
  • code/core/src/common/js-package-manager/vite-plus-versions.ts
💤 Files with no reviewable changes (1)
  • code/core/package.json

📝 Walkthrough

Walkthrough

Removed vite-plus from devDependencies while maintaining it as a peer dependency, and added a TypeScript suppression comment to acknowledge that the dynamic import of vite-plus/versions may fail at type-check time.

Changes

Cohort / File(s) Summary
TypeScript Error Suppression
code/core/src/common/js-package-manager/vite-plus-versions.ts
Added // @ts-expect-error`` comment before dynamic import of vite-plus/versions to suppress type-checking errors when the module is unavailable.
Dependency Management
code/core/package.json
Removed vite-plus from devDependencies while keeping it declared as an optional peer dependency.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@huang-julien huang-julien merged commit e8dfd05 into next Apr 15, 2026
129 of 139 checks passed
@huang-julien huang-julien deleted the fix/vite-plus-devdepsoxfmt branch April 15, 2026 11:25
JReinhold pushed a commit that referenced this pull request Apr 29, 2026
Build: Remove vite-plus as devDependency
(cherry picked from commit e8dfd05)
@github-actions github-actions Bot added the patch:done Patch/release PRs already cherry-picked to main/release branch label Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build Internal-facing build tooling & test updates ci:normal patch:done Patch/release PRs already cherry-picked to main/release branch patch:yes Bugfix & documentation PR that need to be picked to main branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: The oxfmt can be resolved from viteplus instead of oxfmt on the monorepo, breaking CI scripts and precommit hooks

2 participants