feat(20): export SubscriptionEvent type from shared package
Add SubscriptionEvent interface for frontend consumption of SSE subscription data in onData callbacks. Vite proxy confirmed compatible with SSE streaming (http-proxy passes chunked responses by default).
This commit is contained in:
@@ -1,2 +1,2 @@
|
|||||||
export type { AppRouter } from './trpc.js';
|
export type { AppRouter } from './trpc.js';
|
||||||
export type { Initiative, Phase, Plan, Task, Agent, Message, PendingQuestions, QuestionItem } from './types.js';
|
export type { Initiative, Phase, Plan, Task, Agent, Message, PendingQuestions, QuestionItem, SubscriptionEvent } from './types.js';
|
||||||
|
|||||||
@@ -1,2 +1,13 @@
|
|||||||
export type { Initiative, Phase, Plan, Task, Agent, Message } from '../../../src/db/schema.js';
|
export type { Initiative, Phase, Plan, Task, Agent, Message } from '../../../src/db/schema.js';
|
||||||
export type { PendingQuestions, QuestionItem } from '../../../src/agent/types.js';
|
export type { PendingQuestions, QuestionItem } from '../../../src/agent/types.js';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Shape of events received from tRPC subscription streams.
|
||||||
|
* Used by the frontend in onData callbacks.
|
||||||
|
*/
|
||||||
|
export interface SubscriptionEvent {
|
||||||
|
id: string;
|
||||||
|
type: string;
|
||||||
|
payload: unknown;
|
||||||
|
timestamp: string;
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user