![JAR search and dependency download from the Maven repository](/logo.png)
utils.cacher.js Maven / Gradle / Ivy
const cachingStore = () => {
const cache = {}
return {
add(params, result) {
cache[JSON.stringify(params)] = result
},
find(params) {
const key = JSON.stringify(params)
// eslint-disable-next-line no-prototype-builtins
if (cache.hasOwnProperty(key)) {
return cache[key]
}
return false
},
}
}
export default cachingStore()
© 2015 - 2025 Weber Informatics LLC | Privacy Policy