andywer / andywer/http-event-stream
Allow passing custom Last-Event-Id
未關閉
enhancement
- 主要語言
- TypeScript
- 星號
- 20
- 分支
- 2
- PR 合併指標
- 30 天內沒有已合併 PR
描述
Add an option `lastEventId` to `EventStreamOptions`, so the application can pass a custom last event ID.
This is important to have, so that a user can specify a last event ID per query parameter or similar, since the native DOM `EventSource` does not allow customizing the `Last-Event-Id` header.
Use case: The user wants to stream data from a certain point onwards (e.g. the last time they were online) when opening the stream. The `Last-Event-Id` header is only automatically set when reconnecting an already open stream that had some connectivity issue.
貢獻指南
這個儲存庫沒有索引到貢獻指南
評估
這個 Issue 還沒有評估資料。