znck / vue-runtime-helpers

Reusable helpers to inject styles and normalize component.
MIT License
13 stars 6 forks source link

How to define style within a web component? #3

Open elvisqi opened 5 years ago

elvisqi commented 5 years ago

What problem does this feature solve? I tried to use this plugin to write a UI library, but I found that the styles defined in the component did not take effect, and the template tag in the .vue file could not write style in it, and how to handle it more elegantly.

What does the proposed API look like? the same solution with webpack: https://github.com/vuejs/vue-web-component-wrapper/issues/12#issuecomment-385141573

{ shadowMode: true }

znck commented 5 years ago

It is yet to implement here. vue-loader can be used as a reference.