July 30, 2026 — The unofficial Laracon US Day 3. Get your ticket to The Vibes

You're viewing pre-release documentation — version 4.x is in beta

Features, APIs and behaviour may change before the stable release. View the stable version (3.x)

Divider


Overview#

A thin horizontal line separator. Renders as a 1pt rule. Color resolves from the border-* class if set, otherwise the platform separator color (UIColor.separator on iOS, Material outlineVariant on Android).

Copied!
<native:divider />

<native:horizontal-divider /> is an alias of <native:divider /> exposed for use inside side navigation.

Supported Tailwind classes#

The classes that affect how a divider renders:

Class Effect
border-{palette}-{shade}, border-[#hex], border-theme-{token} Line color
opacity-*, opacity-[0.5] Line opacity
m-*, mx-*, my-*, mt-* / mr-* / mb-* / ml-* Spacing around the divider
dark:border-* Dark-mode color override
ios:border-*, android:border-* Platform-specific color

Examples#

Basic separator#

Copied!
<native:column class="w-full gap-4 p-4">
<native:text class="text-lg font-bold">Section One</native:text>
<native:text>Some content here.</native:text>
<native:divider />
<native:text class="text-lg font-bold">Section Two</native:text>
<native:text>More content here.</native:text>
</native:column>

Themed divider with margin#

Copied!
<native:divider class="border-theme-outline my-2 mx-4" />

In a list#

Copied!
<native:column class="w-full">
@foreach($items as $item)
<native:column class="w-full p-4">
<native:text class="text-base">{{ $item->name }}</native:text>
</native:column>
@unless($loop->last)
<native:divider />
@endunless
@endforeach
</native:column>

Thicker rule (use a column)#

Copied!
<native:column class="w-full h-1 bg-theme-outline my-4" />

Element#

Copied!
use Native\Mobile\Edge\Elements\Divider;
 
Divider::make()->borderColor('#E2E8F0');
  • make() - Create a divider