Getting Started
Writing content
API Documentation
Customization
Recipes
API References Develop
@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
strategy
CacheStrategy<TData, T> | undefined

Cache strategy

valid
boolean