How can I use Vue's render() function with Quasar components? #17792
Unanswered
wiese42
asked this question in
General - Components / Directives / etc
Replies: 1 comment 2 replies
-
Suggests that |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am trying to use Vue's render function to create a piece of DOM for a Quasar component. So I try
const elem = document.createElement('div')
const vNode = h(QCard, { class:'my-card' })
render(vNode, elem)
Unfortunatelly this will create an error indicating the the quasar component somehow is undefined
chunk-W5AEE7CF.js?v=71eb7514:1696 Uncaught TypeError: Cannot read properties of undefined (reading 'dark')
at constructor.$e1 (
When I try this with my own Component that does NOT use Quasar components it works fine. We I use quasar components inside my component I get the same error as above.
I should be noted that I tried this with QCard, QItem, QBtn, and QBadge. Interestingly enough, it worked for QBadge, but not for the others.
Maybe someone can try to explain what's going on, and maybe even suggest how to accomplish my task.
If anyone is wondering why on earth I try to use render() with quasar component, I am trying to hook into a third party graph component that provides a means to display your own tooltips. The means consists in providing the DOM element that represents the tooltip.
Beta Was this translation helpful? Give feedback.
All reactions