![](https://img-blog.csdnimg.cn/20201014180756923.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
ts
LLL_LH
记录一些学习心得
展开
-
any Property 'setCheckedKeys' does not exist on type 'Vue | Element | Vue[] | Element[]'.
this.$refs.tree.setCheckedKeys(keys);报错 解决办法:加类型断言 (this.$refs.treeasany).setCheckedKeys(keys);原创 2019-11-12 15:52:00 · 839 阅读 · 0 评论 -
typescript接口设置只读和任意类型
interface student { readonly id: string; // 只读属性 name: string; age?: number; // 可选属性 gender: string; [propName: string]: any // 任意属性 } let Jhon = { id: '20101102', name: 'Jhon', ag...原创 2019-10-30 17:25:38 · 1087 阅读 · 0 评论