Umbral
Back to plugin directory
UL

Umbral Live Reload

Official by Umbral contributors

dev file watcher, SSE reloads, CSS hot-swap

official beta

About

The edit-save-alt-tab-refresh loop is a tax you pay hundreds of times a day. Umbral Live Reload deletes it: save a template, some CSS, or an asset and the browser refreshes itself — and CSS hot-swaps in place without even a full reload. A file watcher pushes events over SSE and the client script injects itself into HTML responses. It's completely inert in production, so there's nothing to strip before you ship.

Install

cargo add umbral-livereload

Wire it up

Point it at the directories you edit.

use umbral::prelude::*;
use umbral_livereload::LiveReloadPlugin;

let app = App::builder()
    .database("default", pool)
    .plugin(LiveReloadPlugin::new().watch("plugins"))  // watch plugin templates too
    .build()?;

Target: a monorepo with per-plugin templates

.watch(dir) adds a directory to the watch set, so a framework built out of plugins reloads on edits anywhere in the tree, not just the top-level templates.

What you get

  • Auto browser refresh on template / asset save
  • CSS hot-swap in place — no full reload for a style tweak
  • SSE-driven; the client script auto-injects into HTML
  • Add extra watch roots with .watch(dir)
  • Fully inert outside dev mode — nothing to remove for prod

Usage

Add `LiveReloadPlugin::new()` and chain `.watch(dir)` for each extra directory to watch (the site templates + static are watched by default). It's automatically inert outside dev mode, so it's safe to leave wired in.

plugin setup
cargo add umbral-livereload

Feature tracker

Per-feature shipping status, recorded in the directory.

6 of 6 shipped
File watcher shipped Beta

Watches templates, static assets, and custom roots.

SSE reload stream shipped Beta

Pushes reload events to connected browsers.

CSS hot-swap shipped Beta

Stylesheets refresh in place without a full page reload.

Client auto-injection shipped Beta

HTML responses receive the live-reload script in dev mode.

SharedWorker fallback usable Beta

SharedWorker path falls back to EventSource when needed.

Production inertness shipped Stable

No watcher or client injection outside development.

Compatibility

Declared support per Umbral version and database backend.

No compatibility rows declared yet.

Community notes

0 notes in the discussion thread.

No notes yet. Be the first to share how this plugin works for you.

Reported issues

Bugs and abuse reports filed against this plugin.

Report an issue

No open issues

No issues have been reported against this plugin. Track upstream bugs on the maintainer's tracker, or report a directory problem to the Umbral team.