摘要: var ll = {} for (var i = 0; i < localStorage.length; i++) { var key = localStorage.key(i); //获取本地存储的Key ll[key] = localStorage.getItem(key) } console. 阅读全文
posted @ 2023-10-19 14:45 外行的小白 阅读(338) 评论(0) 推荐(0) 编辑
摘要: let obj = { name: '张三', user: { name: 'hdcms', }, data: [], }; function copy(object) { let obj = object instanceof Array ? [] : {}; for (const [k, v] 阅读全文
posted @ 2023-10-19 10:23 外行的小白 阅读(5) 评论(0) 推荐(0) 编辑