Inertia Integration¶
Note
This page has moved to the Inertia.js section for comprehensive documentation.
The Inertia.js documentation has been reorganized into a dedicated section with focused pages:
Getting Started¶
Installation - Installation and setup
Configuration - InertiaConfig reference
How It Works - Protocol overview
The Basics¶
Data & Props¶
Shared Data - Shared props
Partial Reloads - Lazy props and partial reloads
Deferred Props - Deferred loading
Merging Props - Infinite scroll
Security¶
CSRF Protection - CSRF configuration
History Encryption - History encryption
TypeScript¶
TypeScript Integration - TypeScript integration
Type Generation - Type generation config
Typed Page Props - Typed page props
Shared Props Typing - Shared props typing
Quick Reference¶
Installation:
pip install litestar-vite
Basic Usage:
from litestar import Litestar, get
from litestar_vite import ViteConfig, VitePlugin
@get("/", component="Home")
async def home() -> dict:
return {"message": "Hello, World!"}
app = Litestar(
route_handlers=[home],
plugins=[
VitePlugin(config=ViteConfig(dev_mode=True, inertia=True)),
],
)
Helpers:
Response Classes:
See Also¶
Inertia.js - Complete documentation
Fullstack Example - Production example