随笔分类 -  前端

摘要:console.log(JSON.stringify(new Error('错误信息'), ['name', 'message', 'stack'])) 阅读全文
posted @ 2022-09-06 20:16 W-it-H-ou-T 阅读(315) 评论(0) 推荐(0) 编辑
摘要:var Crypto = {}; Crypto.sha1_hmac = function (msg, key) { "use strict"; var oKeyPad, iKeyPad, iPadRes, bytes, i, len; if (key.length > 64) { // keys l 阅读全文
posted @ 2022-07-27 21:18 W-it-H-ou-T 阅读(299) 评论(0) 推荐(0) 编辑
摘要:邮箱:/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2, 阅读全文
posted @ 2022-03-24 11:05 W-it-H-ou-T 阅读(25) 评论(0) 推荐(0) 编辑
摘要:URLSearchParams 接口定义了一些实用的方法来处理 URL 的查询字符串。 获取 URL 参数 const url = 'http://xxx.com?id=123&name=hello&age=18'; const search = window.location.search; // 阅读全文
posted @ 2022-02-24 11:38 W-it-H-ou-T 阅读(151) 评论(0) 推荐(0) 编辑
摘要:例: 主项目地址为: http://xxx.com, 想配置 xxx.com/newproject 为另一个项目 1. 修改 vue.config.js 中的publicPath (publicPath: '/newproject') // 新项目的静态资源打包路径, 如访问 xxx.com/new 阅读全文
posted @ 2021-07-07 11:39 W-it-H-ou-T 阅读(176) 评论(0) 推荐(0) 编辑
摘要:overflow : hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; 阅读全文
posted @ 2021-03-10 15:31 W-it-H-ou-T 阅读(42) 评论(0) 推荐(0) 编辑
摘要:<template> <div :style="styleText" class="div1"> <button @click="handleClick">修改颜色</button></div> </template> <script> export default { data () { retu 阅读全文
posted @ 2021-02-26 16:07 W-it-H-ou-T 阅读(1320) 评论(2) 推荐(0) 编辑
摘要:封装 IndexedDB 初始化数据库 dbInit () { return new Promise((resolve, reject) => { const connection = window.indexedDB.open('dbname', 2) connection.onsuccess = 阅读全文
posted @ 2020-12-15 19:59 W-it-H-ou-T 阅读(2288) 评论(0) 推荐(0) 编辑
摘要:Red = 255 × ( 1 - Cyan / 100 ) × ( 1 - Black / 100 ) Green = 255 × ( 1 - Magenta / 100 ) × ( 1 - Black / 100 ) Blue = 255 × ( 1 - Yellow / 100 ) × ( 1 阅读全文
posted @ 2020-12-05 14:58 W-it-H-ou-T 阅读(567) 评论(0) 推荐(0) 编辑
摘要:1 function strToRGB (str = '', opacity = 1) { 2 const resultOpacity = isNaN(Number(opacity)) ? 1 : (opacity > 1 ? 1 : Number(opacity)) 3 const arr = A 阅读全文
posted @ 2020-11-23 13:07 W-it-H-ou-T 阅读(264) 评论(0) 推荐(0) 编辑
摘要:版本1: function process(arr, ...rest) { const cache = []; let t; function check(item) { let trueList = []; let args; for(args of rest) { trueList.push(i 阅读全文
posted @ 2020-01-17 14:28 W-it-H-ou-T 阅读(605) 评论(1) 推荐(0) 编辑
摘要:创建注册表文件: openFiddler.reg 存放在E:\test\openFiddler.reg Windows Registry Editor Version 5.00 [HKEY_CLASSES_ROOT\protocolName]@="protocolName Protocol""URL 阅读全文
posted @ 2019-07-03 17:25 W-it-H-ou-T 阅读(450) 评论(0) 推荐(0) 编辑
摘要:Blob 格式 Excel 文件下载 阅读全文
posted @ 2019-06-10 19:01 W-it-H-ou-T 阅读(4087) 评论(0) 推荐(0) 编辑
摘要:Vue 指定 DIV 导出 PDF 阅读全文
posted @ 2019-06-10 18:53 W-it-H-ou-T 阅读(1497) 评论(0) 推荐(0) 编辑
摘要:vue 项目使用 tracking.js 进行人脸侦测 阅读全文
posted @ 2019-06-10 18:40 W-it-H-ou-T 阅读(6377) 评论(5) 推荐(0) 编辑
摘要:进入/退出全屏 阅读全文
posted @ 2019-06-10 18:10 W-it-H-ou-T 阅读(405) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示