摘要: 在需要引入的页面 初始化加载函数中放入下面代码 // 动态加载jweixin-1.6.0.js 解决ios 问题 const oScript = document.createElement('script') oScript.type = 'text/javascript' oScript.src 阅读全文
posted @ 2020-12-17 17:29 松前月下 阅读(1790) 评论(0) 推荐(0) 编辑
摘要: ###Vant 中的样式默认使用 px 作为单位,如果需要使用 rem 单位,推荐使用以下两个工具: postcss-pxtorem 是一款 postcss 插件,用于将单位转化为 rem lib-flexible 用于设置 rem 基准值 1.下载npm依赖 npm install postcss 阅读全文
posted @ 2020-11-11 17:31 松前月下 阅读(1545) 评论(0) 推荐(0) 编辑
摘要: vuecli2 设置的地方在config下面的index.js vuecli3 新建vue.config.js 疏归同路 万变不离其宗的道理 设置的代理代码如下: proxyTable: { '/api': { target: 'https://demo.com',//代理的网址是https://d 阅读全文
posted @ 2020-09-28 10:50 松前月下 阅读(301) 评论(0) 推荐(0) 编辑
摘要: ####首先需要确保vscode安装的扩展是prettier而不是vscode-prettier! 因为之前安装的扩展是vscode-prettier导致很多问题 打开vscode的设置 找到扩展prettier 进行相关设置 如下图 ps:仅作个人踩坑记录 阅读全文
posted @ 2020-09-26 14:57 松前月下 阅读(7974) 评论(0) 推荐(0) 编辑
摘要: 先声明传递过来函数 在组件里函数调用传过来的函数即可,记得传递过来的函数声明时要加入参数 不然父组件接受不到 阅读全文
posted @ 2020-04-25 11:46 松前月下 阅读(1599) 评论(0) 推荐(0) 编辑
摘要: display: flex;后子元素添加flex grow:0;flex shrink:0; 阅读全文
posted @ 2020-04-03 21:38 松前月下 阅读(1037) 评论(0) 推荐(0) 编辑
摘要: vue2.0脚手架跑不起 config 下面的index host改成loaclhost 就可以了 阅读全文
posted @ 2020-02-27 15:35 松前月下 阅读(195) 评论(0) 推荐(0) 编辑
摘要: ![](https://img2018.cnblogs.com/blog/929957/201912/929957-20191216181133929-1385241243.png) ![](https://img2018.cnblogs.com/blog/929957/201912/929957-20191216181147646-159427272.png) 阅读全文
posted @ 2019-12-16 18:12 松前月下 阅读(1109) 评论(0) 推荐(0) 编辑
摘要: 在vue.configs.js 修改生产过后的文件 module.exports = { publicPath: process.env.NODE_ENV === 'production' ? '您的网址/' : './' } 上面的(你的网址)为上传到一个服务器的网址 用来做绝对路劲 用来给其他任 阅读全文
posted @ 2019-10-17 17:34 松前月下 阅读(698) 评论(0) 推荐(0) 编辑
摘要: import axios from 'axios' import qs from 'qs' const API_URL = '网址' const BASE_URL = `${API_URL}/` const api = axios.create({ baseURL: BASE_URL, withCr 阅读全文
posted @ 2019-07-25 10:19 松前月下 阅读(461) 评论(0) 推荐(0) 编辑