Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vue3 错误提示使用时 报错 createElement is not a function #137

Open
tech-xs opened this issue Mar 2, 2022 · 2 comments
Open

vue3 错误提示使用时 报错 createElement is not a function #137

tech-xs opened this issue Mar 2, 2022 · 2 comments

Comments

@tech-xs
Copy link

tech-xs commented Mar 2, 2022

代码

<template>
  <Mgr>
    <vue-markdown :source="mdText"></vue-markdown>
  </Mgr>
</template>

<script>
import Mgr from '@/components/mgr/Mgr'
import VueMarkdown from 'vue-markdown'

export default {
  name: "WebDoc",
  components: {Mgr, VueMarkdown},
  data() {
    return {
      mdText: '# aaa'
    }
  },
}
</script>
<style lang="less" scoped>
</style>

image

错误内容

vue-markdown.common.js?9ce6:325 Uncaught (in promise) TypeError: createElement is not a function
    at Proxy.render (vue-markdown.common.js?9ce6:325)
    at renderComponentRoot (runtime-core.esm-bundler.js?5c40:893)
    at ReactiveEffect.componentUpdateFn [as fn] (runtime-core.esm-bundler.js?5c40:5030)
    at ReactiveEffect.run (reactivity.esm-bundler.js?a1e9:167)
    at setupRenderEffect (runtime-core.esm-bundler.js?5c40:5156)
    at mountComponent (runtime-core.esm-bundler.js?5c40:4939)
    at processComponent (runtime-core.esm-bundler.js?5c40:4897)
    at patch (runtime-core.esm-bundler.js?5c40:4489)
    at mountChildren (runtime-core.esm-bundler.js?5c40:4685)
    at processFragment (runtime-core.esm-bundler.js?5c40:4856)

推测应该是 highlight.js 库不支持导致的,需要升级应该这个库

@yimiyg
Copy link

yimiyg commented Jun 15, 2023

你解决了么

@kongweigen
Copy link

kongweigen commented Jan 22, 2024

请问解决了吗

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants