MCPcopy Index your code
hub / github.com/TanStack/ai / handleSubmit

Function handleSubmit

packages/ai-solid-ui/src/chat-input.tsx:65–69  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

63 const disabled = () => props.disabled || isLoading()
64
65 const handleSubmit = () => {
66 if (!value().trim() || disabled()) return
67 void sendMessage(value())
68 setValue('')
69 }
70
71 const renderProps = (): ChatInputRenderProps => ({
72 value: value(),

Callers 1

ChatInputFunction · 0.70

Calls 2

disabledFunction · 0.85
sendMessageFunction · 0.50

Tested by

no test coverage detected