摘要: <template> <div> <div class="just-click" @click="clickRect('101')" style="left:200px;top:300px;">101</div> <div class="just-click" @click="clickRect(' 阅读全文
posted @ 2022-01-05 08:34 埃菲尔上的加菲猫 阅读(1977) 评论(0) 推荐(0)
摘要: 在App.vue中添加 mounted() { let width=$("body").width(); if(width>=1200){ //此处1920为自己屏幕的宽度,40位基准值,一般为16px let fontsize=width/1920*40;//fontsize为当前屏幕的基数字体, 阅读全文
posted @ 2021-12-28 16:42 埃菲尔上的加菲猫 阅读(2912) 评论(0) 推荐(0)
摘要: html部分 通常写法: 通过<physical-result></physical-result>显示在页面上 动态引入写法:<component :is="currentView"></component> script部分 先导入组件 import PhysicalResult from '. 阅读全文
posted @ 2021-12-24 09:45 埃菲尔上的加菲猫 阅读(274) 评论(0) 推荐(0)
摘要: vue项目启动,到98%之后就没有然后了 原因: data中图片路径为空 填好路径即可 一度以为电脑的问题,差点重启电脑~~ 阅读全文
posted @ 2021-12-22 17:02 埃菲尔上的加菲猫 阅读(737) 评论(0) 推荐(0)
摘要: localStorage:生命周期是永久,这意味着除非用户显示在浏览器提供的UI上清除localStorage信息,否则这些信息将永远存在。存放数据大小为一般为5MB,而且它仅在客户端(即浏览器)中保存,不参与和服务器的通信。 sessionStorage:仅在当前会话下有效,关闭页面或浏览器后被清 阅读全文
posted @ 2021-12-16 11:09 埃菲尔上的加菲猫 阅读(62) 评论(0) 推荐(0)
摘要: 1.直接执行yarn lint修复 2. vscode自动修复eslint(此方法不太好用,与版本有关系) 安装eslint插件,并启用 文件 首选项 设置 用户,找到setting.json,加上以下配置 "editor.codeActionsOnSave" : { "source.fixAll" 阅读全文
posted @ 2021-12-13 15:49 埃菲尔上的加菲猫 阅读(101) 评论(0) 推荐(0)
摘要: 一:.封装axios 新建util文件夹 > 新建http.js文件 import axios from 'axios' axios.defaults.withCredentials = true const http = axios.create({ baseURL: 'http://123.45 阅读全文
posted @ 2021-12-13 11:22 埃菲尔上的加菲猫 阅读(104) 评论(0) 推荐(0)
摘要: box-sizing: border-box就是将border和padding数值包含在width和height之内,这样的好处就是修改border和padding数值盒子的大小不变。 box-sizing属性的取值可以为content-box或border-box,对它们的解释如下。 ●conte 阅读全文
posted @ 2021-12-09 09:56 埃菲尔上的加菲猫 阅读(4743) 评论(0) 推荐(0)
摘要: position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); 阅读全文
posted @ 2021-12-08 16:48 埃菲尔上的加菲猫 阅读(69) 评论(0) 推荐(0)
摘要: 在router文件下的index.js中添加 import Vue from 'vue'; import VueRouter from 'vue-router'; Vue.use(VueRouter); // 解决ElementUI导航栏中的vue-router在3.0版本以上重复点菜单报错问题 c 阅读全文
posted @ 2021-11-30 08:54 埃菲尔上的加菲猫 阅读(184) 评论(0) 推荐(0)