Skip to content

Commit 9093501

Browse files
committed
add $action docblock
1 parent 2e4e176 commit 9093501

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

packages/router/src/Router.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,25 @@ public function dispatch(Request|PsrRequest $request): Response;
1414

1515
/**
1616
* Creates a valid URI to the given `$action`.
17+
*
18+
* `$action` is one of :
19+
* - Controller FQCN and its method as a tuple
20+
* - Invokable controller FQCN
21+
* - URI string starting with `/`
22+
*
23+
* @param array{class-string, string}|class-string|string $action
1724
*/
1825
public function toUri(array|string $action, ...$params): string;
1926

2027
/**
2128
* Checks if the URI to the given `$action` would match the current route.
29+
*
30+
* `$action` is one of :
31+
* - Controller FQCN and its method as a tuple
32+
* - Invokable controller FQCN
33+
* - URI string starting with `/`
34+
*
35+
* @param array{class-string, string}|class-string|string $action
2236
*/
2337
public function isCurrentUri(array|string $action, ...$params): bool;
2438
}

0 commit comments

Comments
 (0)