上一页 1 2 3 4 5 6 7 ··· 18 下一页
摘要: composition Api中 watch 问题1: watch监听 引用数据类型 reactive 代理的数据时。 newVal 和 oldVal 值一样,无法正确获得oldVal。 解决办法:将引用数据类型拆分为基本数据类型 , 即通过 ref 代理的数据作为监听源数据。 问题2: watch 阅读全文
posted @ 2022-04-08 00:10 Action_swt 阅读(37) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-04-07 22:52 Action_swt 阅读(12) 评论(0) 推荐(0) 编辑
摘要: const beforeUpload = file => { var reader = new FileReader(); reader.readAsDataURL(file); //转化二进制流,异步方法 reader.onload = function(){ //完成后this.result为二 阅读全文
posted @ 2022-04-07 16:34 Action_swt 阅读(3235) 评论(0) 推荐(0) 编辑
摘要: # 使用 npm 安装 CLI $ npm install -g @tarojs/cli # OR 使用 yarn 安装 CLI $ yarn global add @tarojs/cli # OR 安装了 cnpm,使用 cnpm 安装 CLI $ cnpm install -g @tarojs/ 阅读全文
posted @ 2022-04-06 23:41 Action_swt 阅读(215) 评论(0) 推荐(0) 编辑
摘要: 创建附注标签( tag ) $ git tag -a tagName -m "说明" 解释:创建附注标签时,参数-a即annotated的缩写,指定标签类型,后附标签名。参数m指定标签说明,说明信息会保存在标签对象中。 查看 所有创建的 tags $ git tag 推送 创建的 tags $ gi 阅读全文
posted @ 2022-04-02 15:07 Action_swt 阅读(33) 评论(0) 推荐(0) 编辑
摘要: 以上问题都可以通过下面方式解决原因 缓存导致: 1 、yarn cache clean 2 、rm yarn.lock 3 、rm -rf node_modules/ 4 、yarn 还不行的话: 重置本机git设置 git config --global credential.helper sto 阅读全文
posted @ 2022-04-01 15:53 Action_swt 阅读(333) 评论(0) 推荐(0) 编辑
摘要: 初始的时候不存在导致的。 阅读全文
posted @ 2022-03-31 19:06 Action_swt 阅读(400) 评论(0) 推荐(0) 编辑
摘要: type 用于描述一个对象类型。 特点: 1、不能重复 type 2、继承通过 & 3、支持 类型别名,联合类型,元组等类型 interface 接口用来定义一个类的结构,定义类的属性 和 方法。 同时接口也可以当成类型声明去使用。 特点: 1、可以重复声明。 2、接口中的属性都不能定义具体的值,方 阅读全文
posted @ 2022-03-20 23:58 Action_swt 阅读(914) 评论(0) 推荐(0) 编辑
摘要: object 类型 表示 一个 js 对象。实际开发中不常用 object 定义类型。实际限制的是对象下的属性。 因为 js 中. ***** "万物皆对象" ***** 比如 function(){} 、{}....... 实际开发使用: let a : { name: string , age: 阅读全文
posted @ 2022-03-20 14:12 Action_swt 阅读(3004) 评论(0) 推荐(0) 编辑
摘要: void 表示 空值 : null 或者 undefined。 常用于函数返回值设置 never 表示 空值 : 不能为任何值。 可以用于函数在隐士返回undefined之前 抛异常处理 function fn(): never { throw new Error('报错了!') } 阅读全文
posted @ 2022-03-20 13:41 Action_swt 阅读(393) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 ··· 18 下一页