Devs.
In Angular, I miss a good routing mechanism like other web frameworks have
Angular:
editApplication(application: RegisteredApplication) {
this._router.navigate(['/edit-application', application.id]);
}
Other framework:
public void editApplication(Application application) {
setResponsePage(ApplicationPage.class, new
PageParameters().add("app", application));
}
Which is often shortened, if the components implements an interface,
setResponsePage(ApplicationPage.navigate( application));
How about creating a Navigator which would work similarly.
editApplication(application: RegisteredApplication) {
this._navigator.navigate(ApplicationComponent, application);
}
The advantage is that it's type safe and the constants are at a single
point rather than scattered across the web app (or at the component's
class).
WDYT?
Ondra
--
--
Ondrej Zizka, Windup project, Brno
_______________________________________________
windup-dev mailing list
windup-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/windup-dev