laravel-inertia

Standardize Inertia.js v2 protocol and Laravel 12 server-side adapter implementation.

Updated Apr 15, 2026
One-click install
npx skills add https://github.com/gab3mioni/laravel-claudecode-toolkit --skill laravel-inertia
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: laravel-inertia
Source: https://github.com/gab3mioni/laravel-claudecode-toolkit/tree/main/skills/laravel-inertia
Command: npx skills add https://github.com/gab3mioni/laravel-claudecode-toolkit --skill laravel-inertia

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This skill resolves the complexity of managing the Inertia.js v2 protocol in Laravel 12 applications, preventing common issues like stale props, hydration mismatches, and inefficient data loading.

Core Features & Use Cases

  • Prop Strategy Management: Provides a decision framework for choosing between closures, deferred, optional, and merged props to optimize performance.
  • Protocol Enforcement: Ensures correct handling of partial reloads, polling, and history encryption to maintain a seamless SPA experience.
  • Use Case: Use this skill when debugging why page props are stale after a partial reload or when configuring deferred props to improve first-paint performance on data-heavy dashboards.

Quick Start

Invoke the laravel-inertia skill to audit the current controller for inefficient prop evaluation strategies and suggest optimizations.

Frequently Asked Questions about laravel-inertia

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
Why are my Inertia.js props stale after a partial reload in Laravel?

Stale props during partial reloads often occur when controllers evaluate props eagerly instead of using deferred or optional strategies. Enforcing Inertia.js v2 protocol rules ensures partial reloads request only necessary data subsets, preventing outdated page state.

How do I optimize first-paint performance for data-heavy Inertia.js dashboards?

First-paint performance in Inertia.js dashboards improves by configuring deferred props to delay non-critical data evaluation. This strategy sends a lighter initial payload, allowing the page to render before heavier asynchronous data loads.

What is the best way to manage shared data middleware in a Laravel SPA?

Managing shared data middleware in a Laravel SPA requires standardizing shared props through Inertia.js middleware. This approach ensures consistent data transfer across pages without introducing a separate client-side API layer.

Does Inertia.js v2 support server-side rendering with Laravel 12?

Inertia.js v2 supports server-side rendering (SSR) with Laravel 12. Configuring the server-side adapter for SSR compatibility ensures proper hydration and encrypted history state without requiring a separate client-side API layer.

When should I use merged props versus deferred props in Inertia.js?

Use merged props in Inertia.js when combining data from multiple sources into a single payload, and use deferred props when postponing non-essential data evaluation to speed up the initial page render and reduce hydration mismatches.

How do I prevent hydration mismatches when using Inertia.js SSR?

Preventing Inertia.js SSR hydration mismatches requires ensuring server-side and client-side data payloads match exactly. Enforcing the Inertia.js v2 protocol standardizes data transfer and history encryption to maintain synchronization.