# `BB.Kino.EventStream`
[🔗](https://github.com/beam-bots/bb_kino/blob/main/lib/bb/kino/event_stream.ex#L5)

A Kino widget for displaying a live stream of BB messages.

Shows real-time messages from the robot's PubSub with filtering
and pause/resume capabilities.

## Usage

    # Show all messages
    BB.Kino.EventStream.new(MyRobot)

    # Filter to sensor messages only
    BB.Kino.EventStream.new(MyRobot, path_filter: [:sensor])

    # Filter to specific message types
    BB.Kino.EventStream.new(MyRobot,
      path_filter: [:sensor],
      message_types: [BB.Message.Sensor.JointState]
    )

The widget provides:
- Real-time message display with timestamps
- Path and message type filtering
- Pause/Resume functionality
- Click to expand message details

# `new`

```elixir
@spec new(
  module(),
  keyword()
) :: Kino.JS.Live.t()
```

Creates a new event stream widget for the given robot.

## Options

- `:path_filter` - list of atoms for path filtering (default: `[]` for all)
- `:message_types` - list of message type modules to filter by
- `:max_messages` - maximum messages to display (default: 100)
- `:flush_interval_ms` - how often buffered messages are rendered (default: 500)
- `:debounce_window_ms` - how long repeats of the same path + payload type are
  dropped for (default: 1000)

---

*Consult [api-reference.md](api-reference.md) for complete listing*
