Registry / devops / vite-plugin-vinext-payload

vite-plugin-vinext-payload

JSON →
library0.0.19jsnpmunverified

Vite plugin for running Payload CMS (v3.82+) on Cloudflare Workers via vinext, a Vite-based Next.js reimplementation. Current version 0.0.19, experimental. Provides two modes: payloadPlugin() for full Payload with admin UI and REST/GraphQL (requires vinext), and payloadWorkerPlugin() for headless Payload exposing Local API via WorkerEntrypoint RPC (no admin UI, works with any Vite frontend). Key differentiator: enables Payload deployments on Cloudflare Workers with RSC support, reducing cold starts and edge latency. Requires Node >=24, Vite ^8.0.0 (Rolldown). Peer deps pinned to validated stack (Payload 3.84.1, vinext 0.0.50). Includes migration tooling from Next.js and Cloudflare D1 support. Actively developed by Block65.

npm install vite-plugin-vinext-payload
INSTALL
IMPORT
SIG · VITE-PLUGIN-VINEXT
V
vite-plugin-vinext-payload
devopsjavascriptv0.0.19
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

payloadPlugin
✓ import { payloadPlugin } from 'vite-plugin-vinext-payload'
✗ import payloadPlugin from 'vite-plugin-vinext-payload'
Named export, not default. ESM-only.
payloadWorkerPlugin
✓ import { payloadWorkerPlugin } from 'vite-plugin-vinext-payload'
✗ const { payloadWorkerPlugin } = require('vite-plugin-vinext-payload')
ESM-only, no CommonJS support. Named export.
init command
✓ npx vite-plugin-vinext-payload init
✗ npm run init
CLI command, not an npm script. Must be run via npx or after installing the package.

Basic setup for Payload CMS with full admin UI on Cloudflare Workers using vinext.

// vite.config.ts import { defineConfig } from "vite"; import vinext from "vinext"; import { payloadPlugin } from "vite-plugin-vinext-payload"; export default defineConfig({ plugins: [vinext(), payloadPlugin()], });
Debug
Known issues
breakingRequires Node >=24. Older Node versions will fail to install or run.
fix
Upgrade Node to v24 or later.
affects: <24
breakingVite ^8.0.0 required (Rolldown). Vite 5 or 6 will cause peer dependency conflicts.
fix
Update Vite to ^8.0.0, or use --legacy-peer-deps (not recommended).
affects: <8
breakingPayload CMS must be >=3.82.0. Older versions are incompatible.
fix
Update Payload CMS to v3.82 or later.
affects: <3.82
deprecatedPlugin is experimental; APIs may change without major version bump.
fix
Pin to exact version and monitor releases.
affects: 0.x
gotchaWhen using payloadPlugin(), vinext must be installed and configured. Missing vinext will cause build errors.
fix
Run `npm install -D vinext vite` and add vinext() to the Vite config.
affects: all
gotchaThe init command is idempotent but may overwrite manual changes in vite.config.ts. Use --dry-run first.
fix
Run `npx vite-plugin-vinext-payload init --dry-run` to preview changes.
affects: all
Errors
Common errors & fixes
Error: Cannot find module 'vinext'
Missing vinext dependency when using payloadPlugin()
fix
Install vinext: npm install -D vinext
ERR_PNPM_PEER_DEP_MISMATCH
Peer dependency version conflicts with Payload or vinext
fix
Use --legacy-peer-deps during install, or align versions manually.
The current node version is not supported
Node version below 24
fix
Upgrade Node to v24 or later.
TypeError: payloadPlugin is not a function
Wrong import style used (default import instead of named import)
fix
Use import { payloadPlugin } from 'vite-plugin-vinext-payload'
Upgrade
Version history
0.0.19latest on npm
Audit
Dependencies
payloadrequiredPayload CMS runtime required (peer dependency >=3.82.0)
vinextoptionalRequired for full Payload with admin UI (payloadPlugin)
viterequiredVite build tool (peer dependency ^8.0.0)
Agent activity
8 hits · last 30 days
node
8
Resources
vite-plugin-vinext-payload — npm install vite-plugin-vinext-payload · libregistry