Closed mercmobily closed 8 years ago
Aren't the anchor links there for SEO reasons?
Ah, good point. I guess it's impossible to conciliate the two things, right? (keep the links, and still use paper-menu...)
This works:
<paper-menu selected="[[page]]" attr-for-selected="name">
<paper-item name="view1"><a href="/view1">View One</a></paper-item>
<paper-item name="view2"><a href="/view2">View Two</a></paper-item>
<paper-item name="view3"><a href="/view3">View Three</a></paper-item>
</paper-menu>
But it does require some CSS for the link itself....
a.item {
position: absolute;
top: 0;
bottom:0;
left:0;
right:0;
display: inline-block;
text-decoration: none;
color: black;
padding-left: 10px;
padding-top: 12px;
}
a:visited {
text-decoration: none;
color: black;
}
So I guess that's why...?
Guess they're always trying to keep it as simple as possible and guide people in the right direction.
Wouldn't my-app.html be nicer if this:
Became this:
...? The only drawback I can think of is that we don't get to show that
app-location
actually intercepts the page change and updates the location without triggering a page reload.