随笔分类 -  typeScript

摘要:1. number , boolean, string, null, undefind 枚举, any, array数组, 元祖, 2...枚举,需要的注意点, 下一个图,就是为什么yellow 是4 ,会在上一个赋值上+1 3... 函数 ,不确定的 参数用? 表示, 必须 放在 最后 阅读全文
posted @ 2019-03-20 16:26 唐安 阅读(157) 评论(0) 推荐(0)
摘要:重启 vscode, 这个插件 真好用,, 赞个 .... 阅读全文
posted @ 2019-03-16 02:05 唐安 阅读(5975) 评论(0) 推荐(0)
摘要:error TS2585: 'Promise' only refers to a type, but is being used as a value here. Do you need to change your target library? Try changing the `lib` co 阅读全文
posted @ 2019-03-16 01:50 唐安 阅读(11656) 评论(0) 推荐(0)
摘要:1.ts是js的超集,可使用es5,es6的代码 2. ts的安装与编译: a. 首先需要Node.js环境 . 相信都有,略过. 不会的请百度,或者留言. b. npm install -g typescript (如果网络不好, 可尝试 cnpm) c. tsc ts文件名.ts ( ts需要编 阅读全文
posted @ 2019-03-15 16:52 唐安 阅读(230) 评论(0) 推荐(0)