![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
JS
Emma_whm27
这个作者很懒,什么都没留下…
展开
-
JS 时间戳转为日期格式 封装
首先新建一个tool.js, 写入以下代码export function parseDate(time, cFormat) { if (arguments.length === 0) { return null } const format = cFormat || '{y}-{m}-{d}' let date console.log(typeof time) if (typeof time === 'object') { date = time } else原创 2021-03-31 11:30:48 · 214 阅读 · 0 评论 -
VUE + tiff.js 加载 tiff,tif 图片
前段时间公司有个需求,就是前端要加载大量的tif 和 tiff 格式的图片瞬间觉得头大如牛,没有一点思路,于是一直问度娘,功夫不负苦心人,终于让我找到了一款比较好用的插件 tiff.js// 引入依赖npm install tiff.js使用<div class="img-box"> <div ref="imgContainer" class="tifcontent zoomimg" @mousewheel="handleZooming" v-lo原创 2021-02-08 10:15:27 · 6123 阅读 · 7 评论 -
vue + js 实现滚轮缩放图片功能
<template> <img ref="imgContainer" alt="测试 " @mousewheel="handleZoomImg" class="zoomImg" src="../../img/test.png" /></template><script> mounted(){ document.getElementsByClassName('zoomImg')[0].addEve原创 2020-12-28 11:23:19 · 531 阅读 · 0 评论 -
VUE+JS document.execCommand(‘Copy‘)带你实现点击按钮复制文本链接
<template> <div> <div @click="copy('https://www.baidu.com')">点击复制</div> </div></template><script>export default { name: 'search', data () { return {} }, methods: { copy (content) {原创 2020-10-15 15:31:17 · 492 阅读 · 1 评论