自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(14)
  • 问答 (1)
  • 收藏
  • 关注

原创 微信小程序封装wx.request

在utils下面新建request.js文件放下如下代码:const $settings = require(’./settings.js’); //配置文件,配置域名和需要loading层的接口const request = (method, url, data) => {// 开启loading层const loading = KaTeX parse error: Expected 'EOF', got '&' at position 67: …ue); loading &a

2021-04-21 15:51:03 136

原创 VUE后台管理系统权限管理思路

一.有两种做法:(权限就是路由,按钮权限就是控制显示和隐藏)1.权限组放在前端(包括按钮权限)。2.权限组全部由后端返回(包括按钮权限)。二.1.权限组放在前端:根据登录人不同选择不同的权限组。2.权限全部由后端返回:你不管权限,你只要把后端返回的权限组按路由的规则遍历出来添加到Router里面就行了。基本上就是这样。3.按钮权限:把按钮的名称放在一个数组里面,然后在按钮上使用v-if来判断有或者没有显示隐藏就行了。...

2020-11-25 11:16:28 1256

原创 vue动态绑定背景图片

:style="{backgroundImage:‘url(’ + val.banner + ‘)’, backgroundRepeat:‘no-repeat’, backgroundPosition:‘center center’, backgroundSize: ‘cover’}"

2020-08-24 16:23:59 437

原创 vue引入vue-awesome-swiper报错

有些这样import VueAwesomeSwiper from ‘vue-awesome-swiper’import 'swiper/dist/css/swiper.css’不报错,有些会报错就这样引入import VueAwesomeSwiper from “vue-awesome-swiper”;import ‘vue-awesome-swiper/node_modules/swiper/dist/css/swiper.css’...

2020-08-10 17:47:59 659

原创 微信小程序简单的分包

1.在app.json里面加"subpackages": [{“root”: “shoping”,//分包的路径“name”: “shoping”,//分包的名字“pages”: [“pages/home/index”],“independent”: false//是否独立分包},{“root”: “conter”,“name”: “conter”,“pages”: [“pages/new_s/index”],“independent”: false}],...

2020-06-19 11:03:49 505

原创 微信小程序顶部自定义基本上适配所以手机

1.先去设置顶部导航可以自定义2.在app.js里面:wx.getSystemInfo({success: (e) => {this.globalData.statusBar = e.statusBarHeight; //状态栏高度let custom = wx.getMenuButtonBoundingClientRect(); //菜单按钮this.globalData.custom = custom;this.globalData.customBar = custom.bottom

2020-05-10 18:39:29 790

原创 html中使用load,怎么使用被加载页面的id的方法

$(function(){$("#header").load(“new_file.html”,function(){$("#a").on(‘click’,function(){alert(“1111”)});}); })

2020-02-10 16:34:43 601

原创 h5中使用vue+video

<video style="width: 7.5rem;height: 3.0rem;" v-bind:src="mp4url" controls="controls"></video> 注意:路径不要太深了

2020-01-18 17:55:39 765

原创 vue-cil2.0前端解决跨越问题

在config下面的index.js中的module.exports下面的dev加入proxyTable: {‘/api’: {target: ‘http://www.baidu.com’, //源地址changeOrigin: true, //改变源pathRewrite: {‘^/api’: ‘http://www.baidu.com’ //路径重写}}},在使用axiso...

2020-01-08 15:35:42 158

原创 在vue中把时间戳转成时间

在vue中把时间戳转成时间,(如果是10位数需要乘1000,如果13位就不用)timestampToTime(value) {let date = new Date(value);let y = date.getFullYear(); // 年let MM = date.getMonth() + 1; // 月MM = MM < 10 ? (‘0’ + MM) : MM;let ...

2020-01-08 15:21:40 1431 2

原创 vue中判断上传图片大小是否符合

const isImage = file.type.includes("image"); if (!isImage) { this.$message.error("上传文件类型必须是图片!"); return false } var testmsg = /^image\/(jpeg|png|jpg)$/.test(file.type); if (tes...

2019-12-03 16:31:16 1590

原创 vue 中为不同页面设置背景图片

beforeRouteEnter(to, from, next) {document.getElementsByTagName(“body”)[0].className = “bac”;next()},beforeRouteLeave(to, from, next) {document.body.removeAttribute(“class”,“bac”);next();},ba...

2019-11-04 16:13:08 1334

原创 css3动画

1.创建一个动画: @keyframes myfirst{0% {background: #00000}50% {background: red}100% {background: yellow} }2.去相印的要使用动画的元素下面使用animation: myfirst 5s;

2019-11-04 14:53:26 67

原创 vue cli3 使用gzip压缩

vue cli3 使用gzip压缩安装npm install compression-webpack-plugin --save-dev在vue.config.js里面添加const CompressionWebpackPlugin = require(‘compression-webpack-plugin’);// 定义压缩文件类型const productionGzipExtensi...

2019-11-04 14:36:12 677

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除