# @lovable.dev/vite-plugin-hmr-gate

Vite dev-server plugin that waits to send HMR updates until another process says a write batch is complete.

## What It Does

- Buffers selected file watcher events instead of sending immediate browser updates.
- Reports pending files at `GET /__hmr_gate`.
- Flushes queued changes from `POST /__hmr_flush`, either as a full reload or as granular file events.

## Why It Exists

Lovable often writes multiple files as one logical update. Gating HMR keeps the preview from refreshing midway through that batch.
