12 2021 档案

摘要:先上代码: /** * 构造树型结构数据 * @param {*} data 数据源 * @param {*} parentId 父节点字段 默认 'parentId' */ export function handleTree(data, parentId) { const initArr = d 阅读全文 »
posted @ 2021-12-20 10:36 玛卡巴鉲 阅读(52) 评论(0) 推荐(0) 编辑
摘要:1. 属性或参数中使用 ?:表示该属性或参数为可选项 2. 属性或参数中使用 !:表示强制解析(告诉typescript编译器,这里一定有值),常用于vue-decorator中的@Prop 3. 变量后使用 !:表示类型推断排除null、undefined 来自:https://blog.csdn 阅读全文 »
posted @ 2021-12-07 14:59 玛卡巴鉲 阅读(328) 评论(0) 推荐(0) 编辑

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