once
Creates a function that will only execute the provided function once. Subsequent calls will return the cached result from the first execution.
@example
const getValue = once(() => expensiveOperation())
getValue() // executes expensiveOperation
getValue() // returns cached result
function once<T>(fn: () => T): () => T;