最新代码
This commit is contained in:
@ -1,6 +1,9 @@
|
||||
function setStorage(item, value) {
|
||||
return localStorage.setItem(item, JSON.stringify(value));
|
||||
return window.localStorage.setItem(item, JSON.stringify(value))
|
||||
}
|
||||
|
||||
function getStorage(item) {
|
||||
return JSON.parse(localStorage.getItem(item));
|
||||
return JSON.parse(window.localStorage.getItem(item))
|
||||
}
|
||||
|
||||
export {setStorage, getStorage}
|
||||
|
||||
Reference in New Issue
Block a user