inertia-react

Integrate Inertia and React patterns with typed page props in AdonisJS projects.

7|Updated May 6, 2026
One-click install
npx skills add https://github.com/lncitador/adonisjs-maestro --skill inertia-react
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: inertia-react
Source: https://github.com/lncitador/adonisjs-maestro/tree/main/skills/inertia-react
Command: npx skills add https://github.com/lncitador/adonisjs-maestro --skill inertia-react

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

The frontend layer in AdonisJS projects that use Inertia + React often suffers from inconsistent imports, typing, and shared data handling. This skill clarifies how to structure and orchestrate the React frontend with Inertia, ensuring correct usage of AdonisJS components, typed props, and shared state across pages.

Core Features & Use Cases

  • Correct imports from @adonisjs/inertia/react and proper route-name integration in React components
  • End-to-end typing for page props via @generated/data and automatic transformer shapes
  • Shared data orchestration through InertiaMiddleware and inertia.always / inertia.defer patterns
  • Use cases include building Inertia pages, forms, links, and handling deferred/optional props and pagination

Quick Start

Install both inertia-react and adonisjs skills, then start the dev server and begin building with inertia.render() and the React components

Frequently Asked Questions about inertia-react

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

FAQPage Schema
How do I share data across Inertia pages in AdonisJS?

To share data across Inertia pages in AdonisJS, use InertiaMiddleware to orchestrate shared state, applying inertia.always or inertia.defer patterns to control data loading and passing to React components.

How do I type Inertia page props in React for AdonisJS?

Type Inertia page props in AdonisJS by importing types from @generated/data. This ensures end-to-end typing for page props and automatic transformer shapes, maintaining clear separation between backend and frontend concerns.

What's the best way to structure React frontends with Inertia in AdonisJS?

Structure React frontends with Inertia in AdonisJS by importing components from @adonisjs/inertia/react, using Form and Link components, and ensuring typed props from @generated/data for consistent shared data handling.

Does Inertia work with React and AdonisJS for end-to-end typed props?

Yes, Inertia works with React and AdonisJS to provide end-to-end typed page props. By leveraging @generated/data and automatic transformer shapes, you maintain type safety from backend controllers to React components.

How do I use inertia.render with React components in AdonisJS?

Use inertia.render with React components in AdonisJS by ensuring correct imports from @adonisjs/inertia/react, passing typed props from @generated/data, and handling deferred or optional props including pagination.

Why are my Inertia React imports inconsistent in AdonisJS?

Inconsistent Inertia React imports in AdonisJS often occur when not using the correct import paths. Ensure components are imported from @adonisjs/inertia/react and typed data is sourced from @generated/data.