[WIP] Deno as a package manager#1888
Closed
SisyphusZheng wants to merge 2 commits into
Closed
Conversation
- Add Deno variant to PackageManagerType enum - Detect deno.json/deno.jsonc/deno.lock in workspace root - Add Deno to interactive and fallback selectors - Skip npm download for Deno (system binary expected) - Update install docs to list Deno detection signals Refs: voidzero-dev#1886
✅ Deploy Preview for viteplus-preview canceled.
|
Member
|
For the same reasons as #1379 (comment), we currently have no plans. |
SisyphusZheng
added a commit
to open-element/openelement
that referenced
this pull request
Jun 19, 2026
- Add vite-plus dependency via Deno npm: specifier. - Record dogfood observations: vp install falls back to pnpm on Deno project. - Draft RFC issue and WIP PR on Vite+ upstream. - Update VERSION_PLAN.md and roadmap for v0.41.0 realignment. Refs: - voidzero-dev/vite-plus#1886 - voidzero-dev/vite-plus#1888
Author
|
thx for reply |
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.
RFC: Deno as a Vite+ Package Manager
Summary
Add
denoto Vite+ as a first-class package manager alongsidenpm,pnpm,yarn, andbun. When Vite+ detects a Deno project,vp installshould invokedeno installand subsequentvpcommands should respect Deno'sdeno.lock/deno.jsonworkspace model.Motivation
Deno 2 fully supports
package.json,node_modules, and npm dependencies. ForDeno-native projects, the only missing piece of a unified toolchain is a
single-command entry point. Vite+ already provides that for Node/npm projects;
extending it to Deno would make Vite+ a true "Unified Toolchain for the Web"
rather than a Node-only toolchain.
openElement is a Deno-origin Web Components full-stack framework that already
uses Vite and Nitro. It is an ideal dogfood: ESM-first, Web Standards-first,
multi-package workspace, with no desire to migrate to Node/npm. Having Vite+
recognize Deno would let such projects keep their runtime and package manager
while gaining a unified dev/build/check/test/pack entry point.
Scope
Package-manager detection
Detect Deno when any of the following are present (in descending priority):
packageManager: "deno@x.y.z"inpackage.jsondevEngines.packageManager.name === "deno"inpackage.jsondeno.json/deno.jsoncat the workspace rootdeno.lockat the workspace rootdenobinary available on PATH (fallback)vp installWhen Deno is detected, invoke:
Pass through extra args (
--frozen,--allow-scripts, etc.) where semanticallycompatible.
Enum / selector updates
Add
denoto the internalPackageManagerenum and the interactiveselectPackageManagerpicker.Guards for Deno-specific behavior
Deno does not use:
.yarnrc.yml/ yarn resolutionspnpm-workspace.yaml/ pnpm overrides / pnpm catalogs.bunfig.toml/ bun untrusted buildspackage-lock.jsonVite+ should skip these code paths for Deno instead of falling through to an
npm/pnpm/yarn/bun branch.
Non-Goals
vp envinstalling Deno). Denois used as a system package manager, like npm/pnpm/yarn/bun already are.
deno.jsonwithpackage.jsonworkspaces. Deno'sdeno.jsonworkspace convention should remain valid.vp add/remove/updatecanbe deferred;
vp installis the MVP.Node; this proposal is about package-manager dispatch.
Case Study: openElement
openElement is a Web Components full-stack framework built on Deno. It has:
deno.jsonworkspacedeno.lockas the lockfilenpm:specifiersCurrent behavior when running
vp installon openElement:deno.json/deno.lock.pnpmand createspnpm-lock.yaml.Expected behavior:
vp installrunsdeno install.deno.lockremains the source of truth.Repository: https://github.com/open-element/openelement
Implementation Notes
Audit of
vite-plus@0.2.1suggests:detectWorkspace, returningpackageManagerName.vp installcommand dispatch is handled by the Rustrun/runCommandbinding.
PackageManager = { pnpm, npm, yarn, bun }andpattern-matches it in many places.
Therefore the change is split across:
detectWorkspacewith Deno signals; mapvp installto
deno install.denoto the enum/selector; add guards inrewriting/bootstrap logic so Deno is not mis-handled.
Suggested Detection Order Update
Update
docs/guide/install.mdto list Deno signals afterbun.lock/bun.lockband before the fallback:
Open Questions
devEngines.packageManagerwhen bootstrapping a Denoproject, or should it prefer recording the package manager in
deno.json?deno.jsonworkspacearray)?vp installon Deno pass--frozenby default to match pnpm/yarnbehavior, or rely on Deno's own defaults?
binary in CI?
Related
package.jsonandnode_modulessupport:https://docs.deno.com/runtime/fundamentals/configuration/