flarum-bot c2ec848744 Bundled output for commit 187b5c6f0bc5976fa501ca979f704dac26e3f3a5
Includes transpiled JS/TS, and Typescript declaration files (typings).

[skip ci]
2021-12-13 01:41:29 +00:00

12 lines
472 B
TypeScript

import Model from '../Model';
/**
* The `computed` utility creates a function that will cache its output until
* any of the dependent values are dirty.
*
* @param {...String} dependentKeys The keys of the dependent values.
* @param {function} compute The function which computes the value using the
* dependent values.
* @return {Function}
*/
export default function computed<T, M = Model>(...args: [...string[], (this: M, ...args: unknown[]) => T]): () => T;