From 584e9c0b0749a6ed0c5f2b810feb431da9771112 Mon Sep 17 00:00:00 2001 From: Herberts <80950643+HerbertsVaadin@users.noreply.github.com> Date: Thu, 6 Aug 2026 09:13:30 +0300 Subject: [PATCH] #3226 fix navigation anti-pattern (#5854) --- articles/flow/routing/navigation.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/articles/flow/routing/navigation.adoc b/articles/flow/routing/navigation.adoc index 0391cfe2c1..40db5094fd 100644 --- a/articles/flow/routing/navigation.adoc +++ b/articles/flow/routing/navigation.adoc @@ -20,14 +20,14 @@ Compared to [classname]`String` versions, this avoids having to generate the rou In the browser, the [methodname]`navigate()` method triggers a location update and the addition of a new history state entry, but doesn't issue a full page reload. -*Example*: Navigation to the `company` route target when clicking a button: +*Example*: Navigation to the `UserEditor` view when clicking a button: [source,java] ---- Button button = new Button("Navigate to company"); button.addClickListener(e -> button.getUI().ifPresent(ui -> - ui.navigate("company")) + ui.navigate(UserEditor.class)) ); ----