CLI

Overview

The wvb command-line tool packs your web assets into .wvb bundles and drives the full upload, deploy, and download workflow.

The wvb command-line tool packs your built web assets into .wvb bundles and drives the full remote update workflow: upload, deploy, download, and inspect bundles on a remote server. It ships in the @wvb/cli package and exposes two equivalent binaries, wvb and webview-bundle.

Install it as a dev dependency:

npm install -D @wvb/cli
npx wvb --help
pnpm add -D @wvb/cli
pnpm wvb --help
yarn add -D @wvb/cli
yarn wvb --help

Most commands read their defaults from a wvb.config file discovered in the working directory, so a typical project runs wvb pack or wvb upload with no arguments at all. Each command has its own page with the full option reference. To call the same logic from JavaScript, see the programmatic API.

Global flags

Three flags apply to every command. They control output formatting and logging only.

FlagValues / typeDefaultEnvDescription
--coloroff | on | autoautoCOLORColor mode for output. auto enables color on a TTY or in CI.
--log-leveldebug | info | warning | errorinfoLOG_LEVELMinimum log level to print.
--log-verbosebooleanfalseVerbose logging with timestamps and categories.

--config (-C) and --cwd are not global. They are declared per command and are present on most of them. extract accepts --cwd but has no --config, and remote local accepts neither. Where present, --config <path> points at a specific config file and --cwd <dir> changes the directory used to resolve paths.

Boolean flags accept --flag, --flag=true|false, and a --no-flag negation. For example, --no-write and --no-pack turn off the --write and --pack defaults.

Config file discovery

Commands load defaults from a wvb.config file in the working directory. Pass --config <path> to point at a specific file; otherwise wvb searches for the first matching file in this order:

wvb.config.js
wvb.config.cjs
wvb.config.mjs
wvb.config.ts
wvb.config.cts
wvb.config.mts
webview-bundle.config.js
webview-bundle.config.cjs
webview-bundle.config.mjs
webview-bundle.config.ts
webview-bundle.config.cts
webview-bundle.config.mts
wvb.config.json
wvb.config.jsonc

Both the wvb.config and webview-bundle.config base names support the .js, .cjs, .mjs, .ts, .cts, and .mts extensions. The .json and .jsonc extensions are supported for the wvb.config base name only. See Configuration for the full schema.

Commands

On this page