feat: emit User autocommand events for server lifecycle #40

Merged
barrettruth merged 2 commits from feat/user-events into main 2026-03-22 17:52:28 +00:00
barrettruth commented 2026-03-22 17:47:50 +00:00

Problem

There was no way for external code to react to live-server state changes such as starting, stopping, or reloading.

Solution

Fire LiveServerStarted, LiveServerStopped, and LiveServerReload User autocommands with relevant data (port, root, css_only) at each lifecycle point. Document the new events in vimdoc under a new EVENTS section.

## Problem There was no way for external code to react to live-server state changes such as starting, stopping, or reloading. ## Solution Fire `LiveServerStarted`, `LiveServerStopped`, and `LiveServerReload` `User` autocommands with relevant data (`port`, `root`, `css_only`) at each lifecycle point. Document the new events in vimdoc under a new `EVENTS` section.
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
barrettruth/live-server.nvim!40
No description provided.