随笔分类 -  js

摘要:使用场景 后端传递嵌套数据 菜单权限等 树结构转数组 /** * 树结构转数组 * @param {Object} arr 树结构 */ export const treeToList = (arr) => { let tree = JSON.parse(JSON.stringify(arr)); 阅读全文
posted @ 2022-07-26 12:05 流云君 阅读(257) 评论(0) 推荐(0) 编辑
摘要:文字转语音 SpeechSynthesisUtterance是HTML5中新增的API,用于将指定文字合成为对应的语音 function sayTTS(content) { const synth = window.speechSynthesis; const msg = new SpeechSyn 阅读全文
posted @ 2022-07-26 11:57 流云君 阅读(1298) 评论(0) 推荐(0) 编辑
摘要:1.按钮 <el-button @mousedown="down" @touchstart="down" @mousemove="move" @touchmove="move" @mouseup="end" @touchend="end" @touchcancel="end" > </el-butt 阅读全文
posted @ 2022-07-26 11:41 流云君 阅读(247) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示