Releases: elixir-volt/volt
Releases · elixir-volt/volt
v0.14.12
v0.14.9
Added
- Plugins can expose real-file-derived embedded modules through
Volt.Plugin.EmbeddedModulequery ids for custom file formats. - Embedded script and style modules participate in production builds, dev serving, CSS handling, JavaScript checks, and HMR invalidation.
v0.14.7
Added
:hmr_timeoutoption onVolt.DevServer(and the:serverconfig profile) controls the HMR websocket idle timeout. Defaults to60_000ms.- CSS
@importandurl()relationships are now tracked through Vize's parser-backed CSS selectors so HMR can invalidate and hot-swap stylesheets, CSS modules, and framework-emitted styles when an imported stylesheet or referenced asset changes. - CSS dependency tracking now resolves extensionless local imports to
.cssfiles and directory imports toindex.cssfiles. - Svelte-emitted styles participate in CSS asset dependency tracking for HMR.
Changed
- CSS dependency graph updates for physical CSS, CSS modules, and framework-emitted styles now flow through one HMR path.
- HMR websocket messages (
ping,pong,update,error) now flow throughVolt.HMR.Message, which usesJSONCodecfor struct<->JSON (de)serialization withJasonperforming the final binary encoding. - Added
json_codecas a runtime dependency.
Fixed
- Cyclic CSS import graphs no longer report the changed stylesheet as its own HMR dependent.
- CSS module and framework-emitted style dependency links are removed when styles stop referencing an asset.
- HMR websocket no longer drops idle connections after 60 seconds. The browser client now sends a periodic
{"type":"ping"}heartbeat, and the server replies with{"type":"pong"}, preventing Bandit's websocketread_timeoutfrom closing an otherwise idle socket. The client also tracks pongs and force-reconnects if the link goes half-open. This eliminates the spurious[Volt] Disconnected. Reconnecting...console noise observed on long-lived demo/dev pages with no file changes.
v0.14.6
v0.14.3
v0.14.2
Fixed
- Production builds now rewrite CommonJS
require()specifiers so bundled browser output does not leak runtimerequire()calls. - Development vendor prebundle scanning now skips dependency/build directories such as
node_modules, avoiding slow dev asset requests in apps with local npm installs. - React, React DOM, and Solid framework proxy modules now derive public exports from the installed packages instead of hardcoded export lists.
Changed
- Centralized common JavaScript extension and Volt path defaults.
v0.14.1
0.14.1
Fixed
- Development vendor prebundling now uses one multi-entry OXC bundle so shared singleton dependencies, such as CodeMirror packages, are loaded only once.
- Development vendor chunk files emitted by the optimizer are now served from the vendor cache.
Changed
- Upgraded
oxcto 0.16.0 andquickbeamto 0.10.16.
v0.14.0
Added
Volt.static_path/2andVolt.static_url/2resolve Volt-managed scripts, stylesheets, and emitted image/font assets with Phoenix-style helper names.mix volt.build --tailwindnow writes a CSS manifest using the existing production manifest format.
Deprecated
Volt.entry_path/2is deprecated in favor ofVolt.static_path/2.
Fixed
mix volt.js.check --type-aware --type-checknow fails on TypeScript compiler diagnostics such astypescript/TS2322.mix volt.build --tailwindnow honorshash: falsefrom Volt config for Tailwind CSS output filenames, while keeping CLI--hash/--no-hashoverrides.
v0.13.1
v0.13.0
Added
env_prefixconfig for choosing which.envvariables are exposed throughimport.meta.env, including Vite-compatible prefixes like"VITE_".asset_url_prefixconfig andmix volt.build --asset-url-prefixfor changing production JavaScript and CSS asset URLs without changing Phoenix output paths.- Production chunk manifests now include richer chunk metadata:
imports,dynamicImports, chunk-localcss, and emittedassets. - Plugin
embedded_modules/3hook for exposing JavaScript-like scripts embedded in custom file formats.
Changed
- Upgraded
oxcto 0.15.1,quickbeamto 0.10.15, andreachto 2.6.1. mix volt.js.checknow supports--type-awareand--type-checkfor TypeScript-aware linting throughtsgolint.- Type-aware checks now analyze Vue and Svelte component scripts via plugin-provided virtual modules while leaving templates on the normal syntax lint path.
- Production builds now tree-shake JavaScript by default, with
tree_shaking: falseandmix volt.build --no-tree-shakingavailable to preserve unused exports. - Code-split dynamic imports now preload dependency chunks and chunk-local CSS when doing so avoids loading waterfalls.
- Code-split production builds now preserve dynamic import facades, rewrite chunk imports by exact resolved specifier, and avoid worker filename collisions.
- HMR boundary lookup now uses a served module graph, with a dedicated glob graph for
import.meta.glob()invalidation. - HMR updates now support self-accepting modules, dependency accept callbacks, multi-dependency accept callbacks, disposal data, CSS import updates, and full-reload fallback more closely to Vite's behavior.
- Production builds now write the final merged manifest once after all entries are built.
- Production JavaScript asset URL imports now emit hashed files and include them in manifest asset metadata.
- Worker build failures now fail the parent build instead of being ignored.
- JavaScript runtime installs now validate package signatures for reused install directories, and named runtimes reject option mismatches.
glob_exis now a direct dependency for HMR glob invalidation.- Volt now dogfoods type-aware JavaScript checks in
mix lint.
Breaking changes
- Custom plugins that return
{:proxy, filename, opts}fromprebundle_entry/1must useVolt.JS.PrebundleEntry.ImportandVolt.JS.PrebundleEntry.Exportentries for:importsand:exports; plain map entries are no longer accepted. - Custom
extract_imports/3plugin callbacks must return{:ok, %Volt.JS.ImportExtractor.Result{}}instead of plain maps.