Package Entry Update for vite-plugin-react-server by white hopePackage Entry Update for vite-plugin-react-server by white hope

Package Entry Update for vite-plugin-react-server

white hope

white hope

What & why

The published vite-plugin-react-server@2.6.0 package points its legacy root package entry fields at files that are not emitted or packed:
main: ./dist/plugin/index.js
module: ./dist/plugin/index.js
types: ./dist/plugin/index.d.ts
The npm tarball instead includes the neutral root entry at dist/index.js and dist/index.d.ts, plus the conditional root exports at dist/plugin/index.client.js and dist/plugin/index.server.js.
This PR points main, module, and types at the emitted root files and adds a types condition to the root export. It also adds a small package-entry verification script so future builds fail if package metadata points at files missing from the build output or packed tarball.
Fixes #

Validation

Reproduced the published package issue with vite-plugin-react-server@2.6.0: main, module, and types all pointed to missing files in the npm tarball.
Watched the new npm run test:package check fail before the manifest fix with missing ./dist/plugin/index.js and ./dist/plugin/index.d.ts.
npm run build
npm run test:package
npm pack --dry-run --ignore-scripts --json . and verified dist/index.js, dist/index.d.ts, dist/plugin/index.client.js, and dist/plugin/index.server.js are packed.
Installed the packed tarball into a temporary TypeScript consumer project and verified import { vitePluginReactServer } from "vite-plugin-react-server" compiles with moduleResolution: "NodeNext".
git diff --check
I also tried npm run test:unit; it currently fails in test/unit/createReactFetcher.test.ts because react-server-dom-esm/client.browser is not resolvable in the local install. That appears unrelated to this manifest-only change, and the package-entry/build/consumer checks above cover the changed surface.

Checklist

chore(release): 2.6.1#173

Merged
nicobrinkkemper merged 1 commit into
mainfrom

Conversation

Owner
Patch release to ship the root-entrypoint fix from #172.

Why

vite-plugin-react-server@2.6.0 shipped main/moduledist/plugin/index.js and typesdist/plugin/index.d.ts, none of which are in the npm tarball. #172 corrects them to the emitted dist/index.* and adds a types condition to the root export. Since 2.6.0 can't be republished, this bumps to 2.6.1 so the fix actually reaches consumers.

Contents

package.json / package-lock.json: 2.6.0 → 2.6.1 (via npm run version:patch). No other changes.

Verified on this branch

npm run build clean
npm run test:package passes (109 entrypoint targets)
npm pack --dry-run includes dist/index.js, dist/index.d.ts, dist/plugin/index.{client,server}.js
full npm test (both envs) green on the same tree

Note

prepublishOnly still only runs npm run build, so the new test:package guard from #172 won't run automatically on publish. Optional follow-up: set prepublishOnly to npm run build && npm run test:package so a broken manifest can't ship again.
chore(release): 2.6.1
795135c
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.
None yet

1 participant

Like this project

Posted Jun 20, 2026

Fixed package entry issues in vite-plugin-react-server by updating to version 2.6.1.