@arkenv/rsbuild-plugin
Exports and transform options for the Rsbuild plugin.
API reference for @arkenv/rsbuild-plugin. Setup recipes:
TanStack Start guide.
Installation
npm install -D @arkenv/rsbuild-plugin
npm install @arkenv/core arktypepnpm add -D @arkenv/rsbuild-plugin
pnpm add @arkenv/core arktypeyarn add --dev @arkenv/rsbuild-plugin
yarn add @arkenv/core arktypebun install --dev @arkenv/rsbuild-plugin
bun install @arkenv/core arktypeOr if you use Zod, Valibot, or another Standard Schema validator:
npm install -D @arkenv/rsbuild-plugin
npm install @arkenv/standardpnpm add -D @arkenv/rsbuild-plugin
pnpm add @arkenv/standardyarn add --dev @arkenv/rsbuild-plugin
yarn add @arkenv/standardbun install --dev @arkenv/rsbuild-plugin
bun install @arkenv/standardExports
| Export | Role |
|---|---|
| default | arkenvPlugin plugin factory |
named arkenvPlugin | Plugin factory |
named arkenvRsbuildPlugin | Host-explicit named alias |
./standard | Standard Schema plugin entry |
Transform options
Pass transform options only. A schema argument is rejected.
| Option | Default | Meaning |
|---|---|---|
schemaPath | auto (env.ts) | Schema module to transform |
clientPrefix | PUBLIC_ | Keys exposed to the client |
| Plus | (none) | All ArkEnvConfig fields except safe |
logger / logLevel | (none) | Logging |
Call arkenvPlugin() (or arkenvRsbuildPlugin()) with no args, or an options
object that includes transform fields (schemaPath, clientPrefix, logging).
Do not pass a schema map or compiled type() to the plugin.