Packages
volt
0.18.1
0.23.0
0.22.1
0.22.0
0.21.0
0.20.0
0.19.4
0.19.3
0.19.2
0.19.1
0.19.0
0.18.1
0.18.0
0.17.11
0.17.10
0.17.9
0.17.8
0.17.7
0.17.6
0.17.5
0.17.4
0.17.3
0.17.2
0.17.1
0.17.0
0.16.0
0.15.5
0.15.4
0.15.3
0.15.2
0.15.1
0.15.0
0.14.12
0.14.11
0.14.10
0.14.9
0.14.8
0.14.7
0.14.6
0.14.5
0.14.4
0.14.3
0.14.2
0.14.1
0.14.0
0.13.1
0.13.0
0.12.0
0.11.3
0.11.2
0.11.1
0.11.0
0.10.9
0.10.8
0.10.7
0.10.6
0.10.5
0.10.4
0.10.3
0.10.2
0.10.1
0.10.0
0.9.2
0.9.1
0.9.0
0.8.4
0.8.3
0.8.2
0.8.1
0.8.0
0.7.1
0.7.0
0.6.5
0.6.4
0.6.3
0.6.2
0.6.1
0.6.0
0.5.0
0.4.3
0.4.2
0.4.1
0.4.0
0.3.0
0.2.0
0.1.0
Elixir-native frontend build tool — dev server, HMR, and production builds powered by OXC and Vize.
Current section
Files
Jump to
Current section
Files
guides/cheatsheets/cli.cheatmd
# CLI
## Mix Tasks
{: .col-2}
### Install
```bash
mix igniter.install volt
```
Set up Volt in a Phoenix project.
### Build
```bash
mix volt.build
mix volt.build --tailwind
```
Build production assets.
### Dev
```bash
mix volt.dev
mix volt.dev --tailwind
```
Start the file watcher.
### Format
```bash
mix volt.js.format
```
Format JS/TS assets with oxfmt.
### Lint
```bash
mix volt.lint
mix volt.lint --plugin react
```
Lint JS/TS assets with oxlint.
### Check
```bash
mix volt.js.check
mix volt.js.check --type-aware --type-check
```
Check formatting and lint (CI-friendly). Use `--type-aware` for TypeScript rules that require type information.
## `mix volt.build` Flags
{: .col-2}
### Entry
```bash
--entry assets/js/app.ts
```
Repeatable for multi-page apps.
### Output
```bash
--outdir priv/static/assets
```
### Asset URL Prefix
```bash
--asset-url-prefix /assets
```
### Target
```bash
--target es2020
```
### Minification
```bash
--no-minify
```
### Source Maps
```bash
--sourcemap hidden
--sourcemap false
```
### Hashing
```bash
--no-hash
```
### Code Splitting
```bash
--no-code-splitting
```
### Tree Shaking
```bash
--no-tree-shaking
```
### Externals
```bash
--external phoenix
--external phoenix_html
```
Repeatable.
### Format
```bash
--format iife
--format esm
```
### Mode
```bash
--mode production
```
### Tailwind
```bash
--tailwind
--tailwind-css assets/css/app.css
--tailwind-source lib/
```
### Resolve Dirs
```bash
--resolve-dir deps
```
Repeatable.
## `mix volt.dev` Flags
{: .col-2}
### Root
```bash
--root assets/src
```
### Watch Dirs
```bash
--watch-dir lib/
--watch-dir assets/
```
Repeatable.
### Tailwind
```bash
--tailwind
--tailwind-css assets/css/app.css
```
### Target
```bash
--target es2020
```