// 导出选中页面 const exptPageList = data => { if (!data) return; const blob = new
Blob([JSON.stringify(data)], { type: 'text/plain;charset=utf-8', }); saveAs(blob
, `页面菜单.json`); }; // 导入页面 const fileLoad = () => { const reader = new
FileReader(); console.log('导入的1', reader.result); reader.onload = () => { const
result= JSON.parse(reader.result); if (Object.prototype.toString.call(result) ==
'[object Object]') { const tempI = menu.pageList.findIndex(item => item.id ==
result.id); if (tempI != -1) { result.id = uuidv1(); } menu.pageList.push(result
); } }; reader.readAsText(refFile.value.files[0], 'utf8'); //
input.files[0]为第一个文件 };

技术
今日推荐
PPT
阅读数 128
下载桌面版
GitHub
百度网盘(提取码:draw)
Gitee
云服务器优惠
阿里云优惠券
腾讯云优惠券
华为云优惠券
站点信息
问题反馈
邮箱:ixiaoyang8@qq.com
QQ群:766591547
关注微信