I’ve created a custom widget that I would like to use in another custom widget. I know custom widgets are created as angualr directives so in theory I should be able to reference them in the template of my other widget:
...my template code
But I don’t know how to reference the .js for my inner widget or how the properties get set on the scope of that inner widget.
Is this possible?
Thanks
David
Hi again. Tough one. Custom widget are really not designed to be nested inside each other. There could probably be ways to do so but it would be pretty hacky. Mind if I ask first what you intend to do? Vincent
Basically I have a widget that generates a table which I use in several places.
I’m using the community edition and don’t have access to fragments and I have a set of controls that need to be on numerous pages so I was making a widget to hold all of those controls and act sort of like a fragment would. I was hoping to pull in my table widget into my fragment like widget.
You would have to share all properties between both widgets to get something working. Something to do with the way we bind page variables to widget properties. Anyway, fragment would be definitively the way to go.
Vincent