MCPcopy Index your code
hub / github.com/TanStack/form / functionalUpdate

Function functionalUpdate

packages/form-core/src/utils.ts:21–28  ·  view source on GitHub ↗
(
  updater: Updater<TInput, TOutput>,
  input: TInput,
)

Source from the content-addressed store, hash-verified

19 * @private
20 */
21export function functionalUpdate<TInput, TOutput = TInput>(
22 updater: Updater<TInput, TOutput>,
23 input: TInput,
24): TOutput {
25 return typeof updater === 'function'
26 ? (updater as UpdaterFn<TInput, TOutput>)(input)
27 : updater
28}
29
30/**
31 * Get a value from an object using a path, including dot notation.

Callers 6

createFormFunction · 0.90
FormApiClass · 0.90
useField.tsxFile · 0.90
LocalSubscribeFunction · 0.90
LocalSubscribeFunction · 0.90
doSetFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected