@ng-doc/builder / Function

handleCacheStrategy

Generic types:T TData

Handles cache provided cache strategy. It will skip or restore the builder based on the strategy on the first run and update the cache on every next run.

Presentation

function handleCacheStrategy(
  id: string,
  strategy?: CacheStrategy<TData, T> | undefined,
  valid: boolean = true,
): OperatorFunction<BuilderState<T>, BuilderState<T>>;

Returns

Parameters

NameTypeDescription
id
string

@param id

strategy
CacheStrategy<TData, T> | undefined

@param strategy - Cache strategy

valid
boolean

@param valid