摘要:
vue实现前进刷新后退不刷新,比如列表页进入详情页,详情页刷新,但是退回列表页,不刷新依旧是当前页码。 列表页: mounted() { this.getPageIndex(); }, methods: { getPageIndex() { if (sessionStorage.getItem('m 阅读全文
摘要:
移动端调试: npm i vconsole -D if (process.env.NODE_ENV 'development') { const VConsole = require('vconsole') // eslint-disable-next-line const my_console = 阅读全文
摘要:
最终达到这样的效果: 以下省略了一些简单的代码,比如组件引入等 1、引入element ui上传组件 <upload-img :pic="form.bgImage" @getUrlFn="getImgUrl" @modalShowFn="getModalStatus"></upload-img> 2 阅读全文
摘要:
1.与远程仓库重新建立关系 git clone git@gitlab.名称.git 2.可以查看本地当前分支,为master git branch 3.本地创建分支,并检出想要的远程分支demo git branch orgin/demo git checkout orgin/demo 或者可以合并 阅读全文
摘要:
1.切换到基础分支,如主干 git checkout master 2.创建并切换到新分支demo git checkout -b demo 3.git branch查看已经在demo分支 4.更新分支代码并提交 git add * git commit -m "demo" git push ori 阅读全文
摘要:
ios系统微信版存在bug,input框获取焦点后键盘弹出,页面被顶起,但键盘消失时,页面没有回弹,下面存在空白区域 在input标签中添加事件 @focus="getFocus('className')" 在methods中添加方法,手动让页面滚回到原来位置 getFocus (className 阅读全文
摘要:
vue+elementUI,icon打包后不显示,需要在build→utils.js文件中修改 1.找到build文件夹下utils.js文件 2.在以下代码片段中加入 publicPath: '../../' if (options.extract) { return ExtractTextPlu 阅读全文
摘要:
1 function downFile(content, fileName){ 2 const dom = document.createElement('a') // 隐藏的a标签,href为输出流 3 const blob = new Blob([content], { type: 'appli 阅读全文
摘要:
App.vue 中meta对象的属性控制是否展示 1 <keep-alive> 2 <router-view v-if="$route.meta.keepAlive"></router-view> 3 </keep-alive> 4 <router-view v-if="!$route.meta.k 阅读全文
摘要:
引入组件 1 <upload-img :profile-url="shopProfile" @getShopProfileFn="getShopProfile" /> 定义方法 getShopProfile(url) { // url }, 组件内容 1 <template> 2 <div> 3 < 阅读全文