diff --git a/resources/views/docs/mobile/4/edge-components/pressable.md b/resources/views/docs/mobile/4/edge-components/pressable.md index 5183bf037..9cc26905d 100644 --- a/resources/views/docs/mobile/4/edge-components/pressable.md +++ b/resources/views/docs/mobile/4/edge-components/pressable.md @@ -95,7 +95,7 @@ a different component method. @verbatim ```blade @foreach ($items as $item) - + {{ $item->name }} @endforeach diff --git a/resources/views/docs/mobile/4/the-basics/routing.md b/resources/views/docs/mobile/4/the-basics/routing.md index 011c95c55..1310ff3de 100644 --- a/resources/views/docs/mobile/4/the-basics/routing.md +++ b/resources/views/docs/mobile/4/the-basics/routing.md @@ -103,11 +103,11 @@ Available cases: The `@navigate` directive triggers navigation directly from your view, with no component method required. It works on any node, so any element can become a navigation target. -The short form takes a route: +The short form takes a route in single quotes: @verbatim ```blade - + View item ``` @@ -125,13 +125,16 @@ To pass data along with the navigation, use the args form — a route followed b The next screen reads the data with `$this->data('source')`, exactly as with `$this->navigate()`. +Double quotes hold a PHP expression rather than a plain route, so `@navigate="/item/42"` won't compile. For a +dynamic route, build the string in PHP: `@navigate="'/item/' . $item->id"`. + ### Transition modifiers Add a transition as a modifier to override the default push animation: @verbatim ```blade - + Present modally ``` @@ -159,17 +162,17 @@ to `replace` or `exitToWeb`: Go back - + Sign out - + Open dashboard ``` @endverbatim -Transition and action modifiers can be combined — `@navigate.replace.fade="/login"`. +Transition and action modifiers can be combined — `@navigate.replace.fade='/login'`. ## Reading params and data