上一页 1 2 3 4 5 6 7 ··· 12 下一页

2020年8月27日

vue-复制

摘要: 1.安装vue-clipboard2 npm install --save-dev vue-clipboard2 2.main.js中添加 import VueClipboard from 'vue-clipboard2' VueClipboard.config.autoSetContainer = 阅读全文

posted @ 2020-08-27 16:46 秃了头也不退休 阅读(235) 评论(0) 推荐(0) 编辑

Nprogress-进度条

摘要: 引入 nprogress yarn add nprogress import NProgress from 'nprogress' import 'nprogress/nprogress.css' //这个样式必须引入 router.beforeEach((to,from,next) => { NP 阅读全文

posted @ 2020-08-27 14:43 秃了头也不退休 阅读(501) 评论(0) 推荐(0) 编辑

vue-directive(自定义指令)

摘要: <button @click="$router.push('/login')" v-botton>directive</button> export default { name: "directive", directives: { botton: { bind: function (el,bin 阅读全文

posted @ 2020-08-27 14:30 秃了头也不退休 阅读(798) 评论(0) 推荐(0) 编辑

2020年8月26日

typescript-interface

摘要: interface Girll{ name:string; age:number; bust:number; } const girl={ name:'大脚', age:18, bust:100 } const screenResume2=( girl:Girl)=>{ girl.age<24 && 阅读全文

posted @ 2020-08-26 15:09 秃了头也不退休 阅读(198) 评论(0) 推荐(0) 编辑

typescript-数组类型的定义

摘要: 简单的定义 const numArr:number[]=[1,2,3] const strArr:string[]=['a','b','c'] const undeArr:undefined[]=[undefined,undefined] 数组中有字符串又有数组的类型 const arr:(numb 阅读全文

posted @ 2020-08-26 14:37 秃了头也不退休 阅读(4611) 评论(0) 推荐(0) 编辑

typescript-函数参数和返回类型的定义

摘要: 方法的返回类型是number function getTotal(one: number, two: number): number { //返回类型是number return one + two } const total = getTotal(1, 2) console.log(total) 阅读全文

posted @ 2020-08-26 11:34 秃了头也不退休 阅读(2002) 评论(0) 推荐(0) 编辑

typescript-定义静态类型和对象类型

摘要: 1.定义静态类型(一旦定义了就不能改变) //错误代码 let count : number=1 count=2 2.对象类型 const xiaoJieJie:{ name:string, age:number } = { name:'大脚', age:18 } console.log(xiaoJ 阅读全文

posted @ 2020-08-26 10:54 秃了头也不退休 阅读(1665) 评论(0) 推荐(0) 编辑

typescript-全局安装

摘要: 1.需求环境 node.js 2.全局安装 typescript npm install typescript -g yarn global add typescript 3.新建文件Demo1.ts function jspang(){ let web: string="Hello World" 阅读全文

posted @ 2020-08-26 10:30 秃了头也不退休 阅读(5775) 评论(0) 推荐(0) 编辑

Cube-ui的使用

摘要: 官网:https://didi.github.io/cube-ui/#/zh-CN/docs/introduction vue create hello-cube-ui vue add cube-ui 阅读全文

posted @ 2020-08-26 09:26 秃了头也不退休 阅读(480) 评论(0) 推荐(0) 编辑

2020年8月25日

mobx-react

摘要: npx create-react-app hello-mobx yarn add mobx mobx-react react-router-dom 使用装饰器 https://www.jianshu.com/p/2e23781c957f 新建文件夹store 新建文件 homeStore.js in 阅读全文

posted @ 2020-08-25 14:29 秃了头也不退休 阅读(1184) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 7 ··· 12 下一页

导航