Skip to content

Function: PromptInput()

ts
function PromptInput(props: UiPromptInputProps): Block;

Defined in: src/renderer/blocks/index.ts:2168

Experimental

PromptInput — chat composer (auto-grow textarea + send button) wired to session state via name. Submits (Enter, or click) resolve the current render with {prompt, data} by default.

Parameters

ParameterType
propsUiPromptInputProps

Returns

Block

Example

ts
Conversation([
  Message([MessageBody({content: 'Hi'})]),
]);
PromptInput({name: 'message', placeholder: 'Ask anything…'});

Matterway Assistant SDK Documentation