Home > rc-js-util > fpOnce
Creates a function that can be called many times but will run at most once.
Signature:
export declare function fpOnce<TArgs extends unknown[], TRet>(initialize: (...args: TArgs) => TRet): (...args: TArgs) => TRet;
Parameter | Type | Description |
---|---|---|
initialize | (…args: TArgs) => TRet |
Returns:
(…args: TArgs) => TRet
See fpOnce().