Skip to content

Commit

Permalink
add tag a to route macro
Browse files Browse the repository at this point in the history
  • Loading branch information
luanfreitasdev committed Oct 9, 2024
1 parent d2c845b commit 1ee9003
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Providers/Macros.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,8 @@ public static function actions(): void
});

Button::macro('route', function (string $route, array $params, string $target = '_self') {
$this->tag('a');

$this->attributes([
'href' => route($route, $params),
'target' => $target,
Expand Down

0 comments on commit 1ee9003

Please sign in to comment.