All rules

Sheath rule

native-unknown-element

NativePHP elements must use recognized names and complete, balanced syntax.
Package
NativePHP
Category
Native
Default severity
error by default
Auto-fix
Auto-fix available

for close typo suggestions on self-closing native: tags

#Why

An unknown native: element fails when NativePHP builds the screen. An incomplete tag, unmatched closing tag, or unclosed element can also break native nesting and prevent the screen from compiling.

#Examples

#Bad

{{-- txet is not registered; text is the intended tag. --}}
<native:txet>Account</native:txet>
{{-- This opening tag is incomplete. --}}
<native:column

#Good

{{-- text is a registered native element. --}}
<native:text>Account</native:text>

#Recognized Elements And Syntax

Recognized names include NativePHP built-ins and child components registered by the application. A bundled element catalog is used when the running application's catalog is unavailable.

Whitespace around a native: prefix is accepted when the installed NativePHP version supports it. Detected native views also allow registered short tag forms.

#Options

The nativeViewPaths option controls which paths allow short native tags. Its default is ['views/native/']. See Native View Detection for configuration and detection behavior.

#Notes

Blade comments, @verbatim, and @php blocks are excluded because they do not produce native markup. Native tag text inside HTML comments, scripts, and styles is still checked because NativePHP processes it during compilation.

Closing tags must match NativePHP's nesting order.

#See Also

Related rules distinguish discarded wrappers and rejected component slots: