vue项目开发遇到需要部分页面要缓存起来,返回时,需要保持上一个页面跳转前的状态。
路由配置
import Vue from 'vue'
import Router from 'vue-router'
Vue.use(Router)
const router = new Ro...
3年前 (2022-04-12)
喜欢
closeWin() {
console.log('关闭')
if (navigator.userAgent.indexOf("MSIE") > 0) {
if (navigator.userAgent.index...
3年前 (2022-04-12)
喜欢
import icons from "@/components/icons";
<icons :type="item.contentType" :is-active="active==index"><...
3年前 (2022-04-12)
喜欢
vue开发 实现 ppt 在线预览 iframe
/**
* @Author: 858834013@qq.com
* @Name: pptView
* @Date: 2022-04-11
* @Desc:
*/
<template>
<div class=...
3年前 (2022-04-11)
喜欢
vue开发 实现pdf预览iframe形式
/**
* @Author: 858834013@qq.com
* @Name: pdf
* @Date: 2022-04-11
* @Desc:
*/
<template>
<div class="...
3年前 (2022-04-11)
喜欢
安装依赖
npm i vue-pdf --save
使用文档
使用文档
实现代码
/**
* @Author: 858834013@qq.com
* @Name: pdf
* @Date: 2022-04-11
* @Desc:
*/
<template>
&...
3年前 (2022-04-11)
喜欢
在用nodejs仿写单页模板扒手的时候,需要处理下载的css文件内的背景图片和字体文件,在处理前,需要先匹配到对应的文件,这里用正则进行文件匹配。
匹配代码
var pattern = /url\((\S*?)\)/g
console.log(res.data.match(pat...
3年前 (2022-04-08)
喜欢
实例
判断字符串是否是以’//‘开头,如果是则追加’http:‘
var u="//www.wanjunshijie.com"
var url = u
if (u.startsWith('//')) {
url = 'h...
3年前 (2022-04-08)
喜欢
uniapp 微信小程序 Ucharts设置字体大小和颜色
使用fontSize和fontColor设置颜色
"fontSize": 11,
"fontColor": "#9FA3AA",
opt...
3年前 (2022-04-08)
喜欢
uniapp微信小程序开发使用charts折线图, Ucharts需要隐藏折线图上面的label字段, 使用dataLabel:false实现。
dataLabel
<view class="charts-box">
<qiun-da...
3年前 (2022-04-08)
喜欢