There should be a @byContent decorator that would allow capturing of arbitrary DOM content that the web component user has placed into a wrapped web component.
So, if popover is a wrapped web component, we want the user to be able to pass our component content to put inside our component.
class PopoverModel extends DOMModel {
@byAttrVal() title;
@byBooleanAttrVal() open = true;
@byContent('section') content;
}
So, once the above model was parsed, there would be a content field that would contain a React component that you could render into the React component that you are wrapping.
Expected Behaviour
This is a feature request.
There should be a
@byContent
decorator that would allow capturing of arbitrary DOM content that the web component user has placed into a wrapped web component.So, if
popover
is a wrapped web component, we want the user to be able to pass our component content to put inside our component.So, once the above model was parsed, there would be a
content
field that would contain a React component that you could render into the React component that you are wrapping.