import { put , get } from "cacache" ; export { put , get } ; export function putJson ( cachePath , key , data ) { return put ( cachePath , key , JSON . stringify ( data ) ) ; } export function getJson ( cachePath , key ) { return get ( cachePath , key ) . then ( obj => JSON . parse ( obj . data . toString ( "utf-8" ) ) ) ; }