Functions
Lodash-like helper functions.
#
isObject
function isObject (input: any): input is object
Checks if the input is typeof 'object'
and not null
.
#
merge
function merge (target: object, ...sources: object[]): any
Recursively merges own properties from sources
to target
. Used in components to merge default options with input options.
#
debounce
function debounce<T extends (...args: any) => any> (
callback: T,
time: number
): (...args: Parameters<T>) => void
Implementation of debounce, which "groups" multiple sequential calls to a function in a single one.
#
throttle
function throttle<T extends (...args: any) => any> (
callback: T,
time: number
): (...args: Parameters<T>) => void
Implementation of throttle, which prevents a function from executing more than once every X milliseconds.