AI SDK RSCcreateStreamableValue

createStreamableValue

Create a stream that sends values from the server to the client. The value can be any serializable data.

Import

import { createStreamableValue } from "ai/rsc"

Arguments

value:

any
Any data that RSC supports. Example, JSON.

Returns

value:

streamable
This creates a special value that can be returned from Actions to the client. It holds the data inside and can be updated via the update method.