UNPKG

@httpc/kit

Version:

httpc toolbox for building function-based API with minimal code and end-to-end type safety

11 lines (10 loc) 352 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.useCache = void 0; const di_1 = require("../di"); function useCache(key) { const container = (0, di_1.useContainer)(); const caching = (0, di_1.RESOLVE)(container, "ICachingService"); return caching.getCache(key); } exports.useCache = useCache;