Skip to content

Core\Sse\Message

One value that arrived on an event stream's script, returned by Core\Sse->receive. topic returns the name of the topic it was published to, and value returns what was published.

Returned by

You get a Core\Sse\Message from these methods:

Members

2 members.

MemberSignature
topictopic(): string
valuevalue(): mixed

Example apps

These complete apps use this class. You can download and run each one.

  • Poll: A live poll with SQLite and server-sent events. Every open page shows each new vote at once, with no extra server and no library.