Install and configure Volt in a Phoenix project
Replaces esbuild and tailwind with Volt — no Node.js required.
Example
mix igniter.install voltThis installer will:
- Remove
:esbuildand:tailwinddeps - Remove
config :esbuildandconfig :tailwindblocks - Update
assets.setup,assets.build, andassets.deployaliases - Add Volt build config to
config/config.exs - Add format and lint config to
config/config.exs - Add
Volt.Formatterplugin to.formatter.exs - Add
Volt.DevServerplug to your endpoint - Configure the automatic Volt watcher in
config/dev.exs - Wire Volt client types into TypeScript configuration
The installer checks tsconfig.json, assets/tsconfig.json, and
assets/js/tsconfig.json. Ordinary JSON configurations retain their settings
and receive explicit declaration files, even when dependencies are excluded.
When none exists, the installer creates a root configuration from a template.
JSONC and configurations using extends or project references are left
unchanged with guidance to include deps/volt/priv/types/client/**/*.d.ts
(relative to the browser configuration). No local ImportMeta declaration
is needed.