網(wǎng)站建設流程草圖企業(yè)網(wǎng)站開發(fā)制作
項目場景:
項目背景如下所示:
使用 HBuilder X 開發(fā) 項目, 調(diào)整頁面時,直接運行到 瀏覽器查看頁面設置效果,導致控制臺出現(xiàn)下述報錯信息
例如:
問題描述
遇到的問題如下所示:
APP 中接收數(shù)據(jù)代碼:
[Vue warn]: Error in onLoad hook: "ReferenceError: plus is not defined"found in---> <Root>
10:01:04.651 [system]ReferenceError: plus is not definedat VueComponent.initBroadcast (webpack-internal:///7lYQ:118:18)at VueComponent.onLoad (webpack-internal:///7lYQ:113:10)at invokeWithErrorHandling (http://localhost:8080/static/js/chunk-vendors.js:4008:26)at push.4UNb.Vue.__call_hook (http://localhost:8080/static/js/chunk-vendors.js:10756:17)at r (http://localhost:8080/static/js/chunk-vendors.js:14596:386831)at a (http://localhost:8080/static/js/chunk-vendors.js:14596:387409)at VueComponent.created (http://localhost:8080/static/js/chunk-vendors.js:14596:9047)at invokeWithErrorHandling (http://localhost:8080/static/js/chunk-vendors.js:4008:57)at callHook (http://localhost:8080/static/js/chunk-vendors.js:6414:7)at Vue._init (http://localhost:8080/static/js/chunk-vendors.js:7199:23)
原因分析:
提示:這里填寫問題的分析:
解決方案:
解決方法:
通過查看報錯日志信息,我們可以看到:
未定義plus,
這是因為直接運行到普通瀏覽器里,而普通瀏覽器不具備plus環(huán)境。
我們運行到手機或 Android App 基座 ,就不會出現(xiàn)上述的報錯信息了。