@kwayteow/utils - v0.6.0
    Preparing search index...

    Interface DeduplicatedFunction<T, R>

    增强版去重Promise函数

    interface DeduplicatedFunction<T extends any[], R> {
        clearCache: () => void;
        clearKey: (...args: T) => void;
        (...args: T): Promise<R>;
    }

    Type Parameters

    • T extends any[]
    • R
    Index

    Properties

    Properties

    clearCache: () => void

    清除所有缓存

    clearKey: (...args: T) => void

    清除特定key的缓存