karol-f / vue-custom-element

Vue Custom Element - Web Components' Custom Elements for Vue.js
https://karol-f.github.io/vue-custom-element/
MIT License
1.97k stars 187 forks source link

Add variant <div is="componentName"></div> #152

Closed alexeysmith closed 5 years ago

karol-f commented 5 years ago

Can you explain it further, with an example?

alexeysmith commented 5 years ago

document.registerElement("my-element", { prototype: /.../, extends: 'div' }); And then in html: <div is="my-element"></div>

karol-f commented 5 years ago

@alexeysmith why wouldn't you do this inside your component?

I want vue-custom-element to be as thin wrapper as possible and not introduce many Vue specific ideas.