MCPcopy Create free account
hub / github.com/TanStack/ai / createSnapshotEvent

Function createSnapshotEvent

packages/ai-devtools/tests/hook-registry.test.ts:532–550  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

530}
531
532function createSnapshotEvent(): HookStateSnapshotEvent {
533 return {
534 eventId: 'evt-snapshot',
535 timestamp: 2,
536 source: 'client',
537 visibility: 'client-state',
538 clientId: 'chat-1',
539 hookId: 'chat-1',
540 threadId: 'thread-1',
541 hookName: 'useChat',
542 framework: 'react',
543 outputKind: 'chat',
544 state: {
545 messages: [{ id: 'message-1', role: 'user', content: 'Hello' }],
546 status: 'ready',
547 isLoading: false,
548 },
549 }
550}
551
552function createUnregisteredEvent(): HookUnregisteredEvent {
553 return {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected