微信小程序console 是一个全局对象,可以直接访问。在微信客户端中,向 vConsole 中输出日志。
方法
console.group(string label)
在调试面板中创建一个新的分组。随后输出的内容都会被添加一个缩进,表示该内容属于当前分组。调用 console.groupEnd之后分组结束。
console.groupEnd()
结束由 console.group 创建的分组
console.log()
向调试面板中打印 log 日志
console.debug()
向调试面板中打印 debug 日志
console.warn()
向调试面板中打印 warn 日志
console.error()
向调试面板中打印 error 日志
console.info()
向调试面板中打印 info 日志
-
微信小程序打开任意公众号文章 wx.openOfficialAccountArticlewx.openOfficialAccountArticle是微信小程序通过小程序打开任意公众号文章api,不包括临时链接等异常状态下的公众号文章,必须有点击行为才能调用成功。
-
wx.onBatteryInfoChange 监听电池信息变化事件 APIwx.onBatteryInfoChange 为微信小程序监听电池信息变化事件 API,,目前只支持监听省电模式的切换,目前仅 iOS 端支持。
-
live-pusher 实时音视频录制媒体组件live-pusher 微信小程序实时音视频录制媒体组件,v2.9.1 起支持同层渲染。需要用户授权 scope.camera、scope.record。
-
open-container容器转场动画组件open-container为微信小程序容器转场动画组件。
-
wx.setStorage 将数据存储在本地缓存中指定的 key 中微信小程序wx.setStorage 将数据存储在本地缓存中指定的 key 中。会覆盖掉原来该 key 对应的内容。除非用户主动删除或因存储空间原因被系统清理,否则数据都一直可用。单个 key 允许存储的最大数据长度为 1MB,所有数据存储上限为 10MB。
-
微信小程序wx.getExtConfig 的同步版本 APIwx.getExtConfig 为微信小程序的同步版本 API。
暂无评论,抢个沙发...