02 2022 档案
摘要:表头水平居中 <template> <el-table :data="tableData" style="width: 100%" :header-cell-style="{textAlign: 'center'}" > <el-table-column prop="date" label="日期"
阅读全文
摘要:1. 按需引入组件 import {Image} from 'element-ui' Vue.use(Image) 2. 在 Table表格 中使用 el-image <el-table-column prop="photo" label="头像"> <template slot-scope="sc
阅读全文
摘要:使用element-ui时,在 Table表格 内使用 Swithc开关 发现没办法正常开关和获取值 经过一番摸索,终于开窍了,记录一下 1. Swithc开关 绑定数据时使用 Table表格 数据内的对应属性值,其中所对应的索引就是 scope.$index 2. 所对应的点击事件 @change
阅读全文
摘要:今天写一个登录页面,根据不同的用户登陆,其权限不同,等于显示不同的路由页面 结果!!!!! 在调用 router.addRoute() 方法时一直报错: router.addRoute is not a function 然后就从头开始看写的逻辑哪里出了问题,排查了半天,最后打印出来 $router
阅读全文
摘要:cursor是CSS中用于定义鼠标在元素标签上的显示样式,如常用的手型鼠标样式 cursor: pointer; 也可以通过url网址指定扩展名一般为.cur的鼠标图片文件。 名称属性代码描述 默认箭头样式 cursor:default 系统默认 箭头样式 手型 cursor: pointer 系统
阅读全文
摘要:今天使用mac安装cnpm镜像时出现了如下错误 npm ERR! code EACCES npm ERR! syscall access npm ERR! path /usr/local/lib/node_modules npm ERR! errno -13 npm ERR! Error: EACC
阅读全文
摘要:1. 使用递归的方式实现深拷贝 1 function deepClone(obj){ 2 let objClone = Array.isArray(obj) ? [] : {}; 3 if (obj && typeof obj 'object') { 4 for(let key in obj){ 5
阅读全文
摘要:<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="wi
阅读全文