Lynx

genui / openui / UseOpenUIStateOptions

UseOpenUIStateOptions

Inputs used to parse OpenUI text and build renderer state.

属性

initialState?

optional initialState: Record<string, unknown>;

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:91


isStreaming

isStreaming: boolean;

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:88


library

library: CoreLibrary<ComponentRenderer<any>>;

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:87


onAction()?

optional onAction: (event: ActionEvent) => void;

参数

范围类型
eventActionEvent

返回

void

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:89


onError()?

optional onError: (errors: OpenUIError[]) => void;

Callback for structured, LLM-friendly errors. See OpenUIError type.

参数

范围类型
errorsOpenUIError[]

返回

void

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:95


onStateUpdate()?

optional onStateUpdate: (state: Record<string, unknown>) => void;

参数

范围类型
stateRecord<string, unknown>

返回

void

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:90


response

response: null | string;

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:86


toolProvider?

optional toolProvider: any;

ToolProvider for Query data fetching — MCP, REST, GraphQL, or any backend.

定义于

@lynx-js/genui/openui/src/core/hooks/useOpenUIState.ts:93

除非另有说明,本项目采用知识共享署名 4.0 国际许可协议进行许可,代码示例采用 Apache License 2.0 许可协议进行许可。