Repository URL to install this package:
|
Version:
4.0.5 ▾
|
import { config } from '../config'
import { fromStringToCache } from './fromStringToCache'
export const updateCachedDocumentCookie = () => {
const cookie = config.get('document').cookie
config.set('cachedDocumentCookie', cookie)
}
export const renewCache = () => {
console.debug('[@skava/cookie] renewing cache')
updateCachedDocumentCookie()
const cookie = config.get('document').cookie
const cache = fromStringToCache(cookie)
config.set('cache', cache)
}