Reputation: 6154
I am trying to add a router to a custom element. The element should have two subviews where user can switch between them. However, I have run into a problem:
export class customElement {
configureRouter(config,router) { ... } //this is not getting called
}
This question is related and an answer to the question states that "It will not work if it is a custom element."
Is there a workaround or is this just not possible?
Upvotes: 0
Views: 189
Reputation: 6632
This is not possible. Custom elements are not the same as routed view-models. And Aurelia offers no way you can easily achieve this with a custom element.
Upvotes: 4