You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For a navigation target that implements HasDynamicTitle, its getTitle method is run after delivering BeforeNavigationEvent to get the title to use when navigation to that view.
It is not legal for a class to both implement HasDynamicTitle and have a @Title annotation, which should be detected at initialization phase.
@Route("blog")
public void BlogPage extends Div implements HasUrlParameter<String>, HasDynamicTitle {
@Override
public void setParameter(BeforeNavigationEvent event, String id) {
showPost(BlogService.get().findPost(id));
}
@Override
public String getTitle() {
return getCurrentPost().getTitle();
}
}
The text was updated successfully, but these errors were encountered:
As it turned out that HtmlComponent already has a getTitle method but with different signature, it was decided to rename HasDynamicTitle::getTitle to getPageTitle to avoid conflicts. And for consistency, the Title annotation is also renamed to PageTitle.
For a navigation target that implements
HasDynamicTitle
, itsgetTitle
method is run after deliveringBeforeNavigationEvent
to get the title to use when navigation to that view.It is not legal for a class to both implement
HasDynamicTitle
and have a@Title
annotation, which should be detected at initialization phase.The text was updated successfully, but these errors were encountered: