View laravel-hotwire on GitHub
1M
v0.91.0
Search 71 components and 72 controllers by name, category or description.
Navbar
Horizontal or vertical navigation with current state, Turbo Frame targets and sticky layout
Navbar
<hw:navbar>
<hw:navbar.item href="#" current>Overview</hw:navbar.item>
<hw:navbar.item href="#">Activity</hw:navbar.item>
<hw:navbar.item href="#">Settings</hw:navbar.item>
</hw:navbar>
Items shortcut
Since 0.77: pass a plain list through :items instead of composing each item. Current state is never inferred — set current explicitly.
<hw:navbar :items="[
['label' => 'Overview', 'href' => '#', 'current' => true],
['label' => 'Activity', 'href' => '#'],
['label' => 'Settings', 'href' => '#'],
['label' => 'Billing', 'href' => '#', 'disabled' => true],
]" />
Items plus composition
Generated items render before the slot, so a common data set can be followed by richer custom items.
<hw:navbar :items="[
['label' => 'Overview', 'href' => '#', 'current' => true],
['label' => 'Activity', 'href' => '#'],
]">
<hw:navbar.item href="#">
<x-lucide-life-buoy class="size-4" />
Support
</hw:navbar.item>
</hw:navbar>