Minga.Events.BufferChangedEvent (Minga v0.1.0)

Copy Markdown View Source

Payload for :buffer_changed events.

Carries the edit delta and source identity so subscribers can do incremental work directly from the event payload without calling back to the buffer.

When delta is nil, the edit was a bulk operation (undo, redo, content replacement) and subscribers should fall back to full sync.

Summary

Types

t()

@type t() :: %Minga.Events.BufferChangedEvent{
  buffer: pid(),
  delta: Minga.Buffer.EditDelta.t() | nil,
  source: Minga.Buffer.EditSource.t(),
  version: non_neg_integer() | nil
}