Skip to content

Function: produce() ​

ts
function produce<T>(base, recipe): T;

Defined in: client/draft.ts:32

The state recipe makes of base, with base left as it was. If the recipe changes nothing, the result is base itself.

Type Parameters ​

Type Parameter
T

Parameters ​

ParameterType
baseT
recipe(draft) => void

Returns ​

T

MIT licence. Tickflare is an independent project and is not affiliated with Cloudflare.