Open kanishk619 opened 20 hours ago
I am not sure if the result is worth it or (IMO) desirable vs the effort and additional processing required.
Instead I would try to encourage to have explicit options from a top level, more like:
<c-card text-color="light" header-style="h2" :footer-visible="False" />
I think the {{ attrs }}
everywhere approach could get a little unwieldy. To build a robust re-usable component, you want something that is difficult to break, creating thought-out options will help achieve this. Opening the door to throwing an attrs
on any sub element, you will quite easily make the component difficult to maintain due to:
Is there possibility of having named {{ attrs }} ?
Consider the below example
I can, for example, send them across using standard attributes like
But this will make it messy in case of multiple attributes. Can we have something like
<c-attrs />
declaration for this?