随笔分类 -  前端技术分享

主要分享前端一些零碎的知识点,有关html,css,js,git,vue等技术
摘要:发出数据的路由 import { useRouter } from 'vue-router'; const router = useRouter(); router.push({ name: '/system/content/mokuai', params: { Id: row.id, code: 阅读全文
posted @ 2022-06-21 22:01 无何不可88 阅读(442) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2022-06-11 15:10 无何不可88 阅读(92) 评论(0) 推荐(0)
摘要:// 日期格式化 export function parseTime(time: string, pattern: string) { if (arguments.length 0 || !time) { return null } const format = pattern || '{y}-{m 阅读全文
posted @ 2022-05-30 20:53 无何不可88 阅读(442) 评论(0) 推荐(0)
摘要:分页组件 <n-pagination v-model:page="state.page2" :page-count="Math.ceil(total2 / 3)" :item-count="total2" :page-size="3" :page-slot="5" /> 每页3条数据 通过计算属性和 阅读全文
posted @ 2022-05-11 16:00 无何不可88 阅读(118) 评论(0) 推荐(0)
摘要:先判断当前数组是否大于0,才会走后面的操作 阅读全文
posted @ 2022-05-09 18:03 无何不可88 阅读(48) 评论(0) 推荐(0)
摘要:<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge" /> <meta name="viewport" content 阅读全文
posted @ 2022-05-05 14:01 无何不可88 阅读(73) 评论(0) 推荐(0)
摘要:<el-table-column v-for="(item, index) in columnTable" :key="index" v-bind="item" show-overflow-tooltip align="center"> </el-table-column> 可以使用v-bind进行 阅读全文
posted @ 2022-04-16 14:27 无何不可88 阅读(762) 评论(0) 推荐(0)
摘要:params:是json格式。 id:是在url后面做拼接 在接口中定义不同的数据。来传递。 阅读全文
posted @ 2022-03-16 15:13 无何不可88 阅读(106) 评论(0) 推荐(0)
摘要:查看远程所有分支 $ git branch -a 创建分支 git branch [branchname] 新建分支并切换到指定分支 git checkout -b master origin/master git checkout -b 本地分支名 origin/远程分支名使用上面的命令可以创建分 阅读全文
posted @ 2022-02-14 10:54 无何不可88 阅读(2616) 评论(0) 推荐(0)
摘要:数组方法 返回新数组 concat() 连接两个或更多的数组,并返回结果 let arr = [1,2,3,4]; let newArr = arr.concat([5,6],7); console.log(newArr); // [1,2,3,4,5,6,7] console.log(arr); 阅读全文
posted @ 2022-02-09 22:05 无何不可88 阅读(114) 评论(0) 推荐(0)
摘要:1.通过循环遍历tab栏 <div class="bigRanking"> <span v-for="(item, index) in navData" :class="{ nav_li : active index }" :key="index" @click="changRanking(inde 阅读全文
posted @ 2021-12-29 10:02 无何不可88 阅读(606) 评论(0) 推荐(0)
摘要:传统面向对象多态 例如: //1>必须有继承(是多态的前提)//2>必须有重写(子类重写父类的方法)//3>必须有父类引用指向子类对象class Shape{ getArea(){} } class Reactangle extends Shape{ getArea(){ return 100 } 阅读全文
posted @ 2021-12-21 21:29 无何不可88 阅读(157) 评论(0) 推荐(0)
摘要:下载 npm 之前需要下载 node,node 官网 http://nodejs.cn/ 傻瓜式安装 国内镜像 npm install -g cnpm --registry=https://registry.npm.taobao.org 拥有镜像可以使用 npx 来提升速度 vue2 的项目脚手架搭 阅读全文
posted @ 2021-12-21 16:44 无何不可88 阅读(862) 评论(0) 推荐(0)
摘要:当文字超出div的宽,以省略号的形式隐藏 1.单行隐藏 white-space:nowrap; overflow:hidden; text-overflow:ellipsis; 2.多行隐藏 word-break: break-all; text-overflow: ellipsis; overfl 阅读全文
posted @ 2021-12-21 16:43 无何不可88 阅读(50) 评论(0) 推荐(0)