会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
顾非白
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
下一页
2019年11月15日
JS截取文件名后缀
摘要: const fileName = file.lastIndexOf('.'); // 取到文件名开始到最后一个点的长度 const fileNameLen = file.length; // 取到文件名长度 const fileType = file.substring(fileName + 1, fileNameLen); // 截
阅读全文
posted @ 2019-11-15 14:55 顾非白
阅读(1994)
评论(0)
推荐(0)
2019年11月9日
微信小程序之打开文档功能
摘要: /* 打开文档 * @param fileUrl: 文件地址 * @param filetype: 文件类型 */ openDocument(fileUrl, filetype) { wx.downloadFile({ url: fileUrl, success: res => { const filePath = res.temp...
阅读全文
posted @ 2019-11-09 09:37 顾非白
阅读(4865)
评论(0)
推荐(0)
微信小程序封装http请求方法
摘要: http请求 删除数据 上传
阅读全文
posted @ 2019-11-09 09:33 顾非白
阅读(1941)
评论(0)
推荐(0)
小程序实现电子签名(wepy@1.7)
摘要: 公司业务需要实现电子签名功能,当前我使用的是wepy框架。 html less ts
阅读全文
posted @ 2019-11-09 09:23 顾非白
阅读(3067)
评论(0)
推荐(1)
js封装常用方法
摘要: 1、数组按createTime排序 function sortByCreateTime(list: any[]) { return list.sort(function(a, b) { return new Date(a.createTime).getTime() - new Date(b.crea
阅读全文
posted @ 2019-11-09 09:07 顾非白
阅读(598)
评论(0)
推荐(0)
2019年11月5日
npm常见命令解析
摘要: 1.npm -v 查看npm当前版本 2.tsc -v 查看typescript当前版本 3.npm install moduleName 安装模块到项目node_modules目录下,运行 npm install 初始化项目时不会下载模块,若此模块已安装,则为升级到最新版本,eg:npm i ty
阅读全文
posted @ 2019-11-05 14:46 顾非白
阅读(793)
评论(0)
推荐(0)
2019年10月23日
js数组方法解析
摘要: join() 1 // 数组转字符串 2 var arr = [1,2,3]; 3 console.log(arr.join()); // 1,2,3 4 console.log(arr.join("-")); // 1-2-3 5 // 通过join()方法可以实现重复字符串,只需传入字符串以及重
阅读全文
posted @ 2019-10-23 17:27 顾非白
阅读(1653)
评论(0)
推荐(0)
es6数组新增的方法
摘要: forEach 循环 1 // 遍历数组,无返回值,不改变原数组,仅仅只是遍历 2 let arr = [2,3,4,5]; 3 arr.forEach((item, index)=>console.log(item)); map 1 // 1个对1个映射, 循环什么最后return什么,不会改变原
阅读全文
posted @ 2019-10-23 16:17 顾非白
阅读(546)
评论(0)
推荐(0)
2019年4月3日
css定义input的disabled样式
摘要: 最近在撸原生代码,input还能更改disabled样式,先做一个记录 1 input:disabled { 2 background-color : #fff; // 修改默认灰色样式 3 color: #666; 4 opacity:1; // 默认的不透明级别为0.3 5 -webkit-te
阅读全文
posted @ 2019-04-03 19:18 顾非白
阅读(4302)
评论(0)
推荐(0)
2018年6月29日
页面跳转,回退第一个页面
摘要: 开发时会遇到这种问题,从A页面跳转→B页面→C页面,使用navigateBack,跳转到上一页,但如果从C页面直接跳转到A页面,在这个过程中直接销毁B页面呢? 可在A页面跳转B页面时: 可在B页面跳转C页面时: 这样在C页面点击回退时,会直接回到A页面。
阅读全文
posted @ 2018-06-29 14:26 顾非白
阅读(705)
评论(0)
推荐(0)
上一页
1
2
3
下一页
公告