0016-laravel-blade-component-patterns

Community

Build reusable, composable Blade UI components.

AuthorMrJmpl3
Version1.0.0
Installs0

System Documentation

What problem does it solve?

It solves the problem of inconsistent, hard-to-maintain Blade view code by providing repeatable patterns for structuring Laravel Blade components and composing UI with slots, attributes, and layouts.

Core Features & Use Cases

  • Class-based and anonymous components: Encapsulate UI behavior and rendering, using php artisan make:component for class-based components and @props for anonymous components.
  • Slots and slot attributes: Create flexible component APIs for headers, footers, and scoped content using named slots (e.g., x-slot:footer) and $slot->withAttributes(...).
  • Powerful attribute bag usage ($attributes): Support consumer customization via merge, class() manipulation, filtering (whereStartsWith, whereDoesntStartWith), and presence checks (has, get, only, except).
  • Reusable UI patterns for real apps: Standardize alerts, cards, form inputs/selects, dynamic component rendering (x-dynamic-component), and layout approaches with @stack.
  • HTMX/Turbo-friendly partial rendering: Use @fragment to return only the needed DOM portion for fast updates.

Quick Start

Ask for a reusable component design for an alert and a form input, including how to merge attributes, support named slots, and render it inside a layout using stacks.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: 0016-laravel-blade-component-patterns
Download link: https://github.com/MrJmpl3/codex_____data_____configuration/archive/main.zip#0016-laravel-blade-component-patterns

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.