I think I am just confused how to use the subrouting component, but the documents and example I have read hasn't really gotten me anywhere.
If anyone could point out the elephant in the room for me that would be great.
What am I trying to Achieve?
I have a list of items(called matters) which I display on my-matters.html (this page currently calls another custom element called matters-list.html which brings through the list)
http://127.0.0.1:8081/matters
I want to be able to click on one of these and go to a details page (I've built this template called matters-details.html
EG: http://127.0.0.1:8081/matters/123
The question :
How do I handle the routing on the my-matters.html
my understanding is that if I add a button to hit the href /matters/123 there should be some app route logic on the my-matter.html page that knows to close the matter-list and open the matter detail?
Or am I going about this wrong and need to add two pages
my-matters-list.html
my-matters-details.html
and in the my-app routing use both there under the url /matters ?
Here is my code taken from the starter kit mostly: my-app.html
I've read : https://www.polymer-project.org/2.0/toolbox/case-study#routing And: https://github.com/PolymerElements/app-route
I think I am just confused how to use the subrouting component, but the documents and example I have read hasn't really gotten me anywhere.
If anyone could point out the elephant in the room for me that would be great.
What am I trying to Achieve? I have a list of items(called matters) which I display on my-matters.html (this page currently calls another custom element called matters-list.html which brings through the list) http://127.0.0.1:8081/matters
I want to be able to click on one of these and go to a details page (I've built this template called matters-details.html EG: http://127.0.0.1:8081/matters/123
The question :
How do I handle the routing on the my-matters.html my understanding is that if I add a button to hit the href /matters/123 there should be some app route logic on the my-matter.html page that knows to close the matter-list and open the matter detail?
Or am I going about this wrong and need to add two pages my-matters-list.html my-matters-details.html and in the my-app routing use both there under the url /matters ?
Here is my code taken from the starter kit mostly: my-app.html
`
my-matters.html :
Matters
`