Fetch data from url and add into cache. If already exists in cache, should return instantly.
The url to the data to be cached. *
Optionalstoretype: stringOnly applies to ArtifactIndexedDBCache. Since indexedDB stores the actual
*
Optionalsignal: AbortSignalAn optional AbortSignal to abort data retrival.
data rather than a request, we specify storagetype. There are two options:
fetch(url).json()fetch(url).arrayBuffer()Delete url in cache if url exists
Retrieve data object that corresponds to url from cache. If data object does not exist in
cache, fetch the data and then add to cache.
The url to the data to be cached. *
Optionalstoretype: stringThis field is required so that ArtifactIndexedDBCache can store the
actual data object (see addToCache()), while ArtifactCache which uses the Cache API can
return the actual data object rather than the request. There are two options:
fetch(url).json()fetch(url).arraybuffer()Optionalsignal: AbortSignalAn optional AbortSignal allowing user to abort the fetching before its completion.
The data object (i.e. users do not need to call .json() or .arraybuffer()).
check if cache has all keys in Cache
Common Interface for the artifact cache