<editor></editor>
- 发布:2024-10-31 14:54
- 更新:2024-10-31 14:58
- 阅读:61
产品分类: uniapp/H5
PC开发环境操作系统: Windows
PC开发环境操作系统版本号: 22H2
HBuilderX类型: Alpha
HBuilderX版本号: 4.17
浏览器平台: Chrome
浏览器版本: 123.0.6262.5
项目创建方式: HBuilderX
示例代码:
操作步骤:
<editor></editor>
chunk-vendors.js:70854 [Vue warn]: Error in mounted hook: "TypeError: Cannot read properties of undefined (reading 'id')"
<editor></editor>
chunk-vendors.js:70854 [Vue warn]: Error in mounted hook: "TypeError: Cannot read properties of undefined (reading 'id')"
预期结果:
正常运行
正常运行
实际结果:
报错chunk-vendors.js:70854 [Vue warn]: Error in mounted hook: "TypeError: Cannot read properties of undefined (reading 'id')"
报错chunk-vendors.js:70854 [Vue warn]: Error in mounted hook: "TypeError: Cannot read properties of undefined (reading 'id')"
bug描述:
使用editor组件,什么都还没做 就 加入了<editor></editor>,就报错了
chunk-vendors.js:70854 [Vue warn]: Error in mounted hook: "TypeError: Cannot read properties of undefined (reading 'id')"
还是LZM (作者)
组件 my-editor:
<template>
<view class="container">
<view class="page-body">
<view class='wrapper'>
<view class="editor-wrapper">
<editor id="editor"></editor>
</view>
</view>
</template>
<script>
export default {
name: "my-editor",
</script>
<style>
/ @import "./editor-icon.css"; /
@import '/style/editor-icon.css';
</style>
2024-10-31 15:14
靐齉齾麤龖龗
回复 还是LZM: 没用复现你的问题。。上传一个可复现的demo吧,或者你更新一下hbx试试
2024-10-31 15:24
还是LZM (作者)
回复 靐齉齾麤龖龗: 另外还有一个问题 :使用uni.createSelectorQuery的时候也会报错,[system] createSelectorQuery:fail
(anonymous) @ chunk-vendors.js:69662
Array.isArray.n.onError.length.n.onError @ chunk-vendors.js:69662
invokeWithErrorHandling @ chunk-vendors.js:72097
push.m44O.Vue.__call_hook @ chunk-vendors.js:78845
o @ chunk-vendors.js:69662
s @ chunk-vendors.js:69662
invokeWithErrorHandling @ chunk-vendors.js:72097
Vue.$emit @ chunk-vendors.js:74166
a @ chunk-vendors.js:69662
v @ chunk-vendors.js:69662
(anonymous) @ chunk-vendors.js:69662
insertAtCursor @ my-cueditor.vue:86
insertTable @ my-cueditor.vue:82
click @ index.js:33869
invokeWithErrorHandling @ chunk-vendors.js:72097
invoker @ chunk-vendors.js:72422
invokeWithErrorHandling @ chunk-vendors.js:72097
invoker @ chunk-vendors.js:72418
original._wrapper @ chunk-vendors.js:77306
chunk-vendors.js:70854 [Vue warn]: Error in v-on handler: "TypeError: Cannot read properties of undefined (reading '$vm')"
2024-10-31 15:37