UNPKG

@tsdotnet/lazy

Version:

Lazy<T> and ResettableLazy<T> class for simplifying lazy initialization.

18 lines (15 loc) 402 B
import Lazy from './Lazy.js'; /*! * @author electricessence / https://github.com/electricessence/ * @license MIT */ class ResettableLazy extends Lazy { constructor(valueFactory) { super(valueFactory, true); } static create(valueFactory) { return new ResettableLazy(valueFactory); } } export { ResettableLazy as default }; //# sourceMappingURL=ResettableLazy.js.map