首页 > 解决方案 > Salesforce LWC Uncaught (in promise) TypeError: Cannot read property 'Symbol(ViewModel)' of undefined

问题描述

运行 Salesforce 临时组织应用程序时出现此错误;

aura_proddebug.js:274 Uncaught (in promise) TypeError: Cannot read property 'Symbol(ViewModel)' of undefined
at getInternalField (aura_proddebug.js:274)
at Object.update (aura_proddebug.js:1793)
at updateCustomElmDefaultHook (aura_proddebug.js:5627)
at Object.update (aura_proddebug.js:5779)
at patchVnode (aura_proddebug.js:5021)
at updateStaticChildren (aura_proddebug.js:5000)
at aura_proddebug.js:5542
at runWithBoundaryProtection (aura_proddebug.js:8255)
at updateChildrenHook (aura_proddebug.js:5541)
at Object.update (aura_proddebug.js:5751)

有谁之前经历过这个吗?

标签: javascriptsalesforcesalesforce-lightninglwc

解决方案


我实际上能够发现问题。

当我没有 .html 文件或者我以某种方式拼写不正确时,我的组织中已经抛出了这个错误;在名称上包括区分大小写。

在这里查看相关:


推荐阅读