ravenq / markdown-it-vue

The vue lib for markdown-it.
MIT License
347 stars 68 forks source link

[Vue warn]: Error in render: "TypeError: _components.default is not a function" #11

Closed maxanstey closed 4 years ago

maxanstey commented 4 years ago

I implemented this markdown editor in my site and received the below error:

[Vue warn]: Error in render: "TypeError: _components.default is not a function"

I get this error when I wrap code in triple back-ticks before I state a valid code type (e.g. javascript) so writing ```test``` for example returns a console error 4 times (as test is 4 characters in length.)

I resolved this issue by commenting out the line (0, _components.default)([lang]); in function loadPrismLang(lang) (c. line 65.)

Please let me know if I'm doing something wrong or if my fix is unsuitable. I'm not 100% sure what that piece of code is actually doing.

Thanks

ravenq commented 4 years ago

Thanks for your issue!

It is may cause by the version of vue or webpack conflict.

It is need more infomation. Show the package.json and code if necessary.

LetMeDream commented 4 years ago

I happen to have this same issue

torressam333 commented 4 years ago

I also have this issue, is there a resolution for this?