Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions articles/flow/testing/browserless/getting-started.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,15 @@ To navigate to another registered view, use the [methodname]`navigate()` methods
+
[methodname]`navigate("template/myParam", Template.class)`

[since:com.vaadin:vaadin@V25.3]#The location is written the way it appears in the browser's address bar, so it can carry a query string and a fragment#:

[source,java]
----
OrderView view = navigate("order/ORD-1?tab=history", OrderView.class);
----

The view reads those query parameters from the navigation event, as it does in a running application. The map that [methodname]`navigate(Template.class, Map)` takes holds route template parameters instead, so a query string belongs in the location string.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A potential addition from #6076

A location consisting only of a fragment, such as "#details", identifies a place within the current page rather than a route, so it leaves the current view in place.

All navigation methods return the instantiated view, so that its fields can be used directly for testing.

[NOTE]
Expand Down
Loading