使用说明
- 如果是vue,react等,以下代码写在index.html中
- 如果是普通的html页面,直接添加在要调试的页面中即可
<script src="path/to/vconsole.min.js"></script>
<script>
// init vConsole
var vConsole = new VConsole();
console.log('Hello world');
</script>
cdn
https://cdn.bootcss.com/vConsole/3.3.2/vconsole.min.js
uniapp中添加index.html使用vconsole (仅在编译成h5时生效)
- 添加index.html、参考uniapp官方文档
https://uniapp.dcloud.io/collocation/manifest?id=h5-template
- 然后将引入vconsole的代码写在index.html中