Dominik
Dominik

Reputation: 1431

What are the main purposes for vaadin router templates

Vaadin URL route templates marked sometimes as cool new feature. I've just started with Vaadin, knowing the principle of routes, but what is the main purpose for those route templates ?

kind regard Dominik

Upvotes: 0

Views: 60

Answers (1)

Mikael Grankvist
Mikael Grankvist

Reputation: 521

The route templates give more flexibility for parameter position and requirements over the basic HasUrlParameter<T> that only handles parameters at the end of the route.

In particular, it allows you to use multiple parameters for the same route or to have URL structures where the parameter is not at the end, e.g products/123/edit where 123 is the parameter that identifies a product id.

For samples and information see https://vaadin.com/docs/latest/flow/routing/templates

Upvotes: 2

Related Questions