![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
typescript
忆达夫
这个作者很懒,什么都没留下…
展开
-
随机生成任意长度字符串
随机生成任意长度字符串原创 2022-08-02 11:23:19 · 462 阅读 · 0 评论 -
array enum 的准替代方案(改进版)
array enum原创 2022-07-04 14:03:34 · 148 阅读 · 0 评论 -
enum 的准替代方案
关键字: typescript enum解决 enum 无法定义多个字段,无法单独获取定义的 key缺点: 暂不支持空 value, 自动递增 valueinterface Item { value: number | string; label: string; [x: string]: any;}abstract class EnumImpl { protected mainKey = 'label' private __: Item[]; construct.原创 2022-01-17 14:51:12 · 421 阅读 · 0 评论 -
vue 组建工程化实战
新增index.mixin.tsimport Vue from 'vue'import { Component } from 'vue-property-decorator'// 公共属性及方法@Componentexport default class extends Vue {}// 双向绑定 modelexport const MixinModal: any = { props: { value: [String, Number, Array, Object, Boo.原创 2021-07-08 15:02:05 · 97 阅读 · 0 评论