--- title: 'Introduction and Concepts' description: 'Learn how Laravel Lang Sync Inertia bridges PHP localization files to frontend Inertia components without duplicated translation keys.' head: - - meta - name: robots content: 'index, follow, max-image-preview:large, max-snippet:-1, max-video-preview:-1' - - meta - name: googlebot content: 'index, follow, max-image-preview:large, max-snippet:-1, max-video-preview:-1' - - meta - name: bingbot content: 'index, follow, max-image-preview:large, max-snippet:-1, max-video-preview:-1' ---
Getting Started
# Introduction **Laravel Lang Sync Inertia** is a lightweight, zero-latency bridge between Laravel's native backend translation ecosystem and Inertia.js frontend applications. It enables you to seamlessly use server-side PHP language files inside **Vue**, **React**, and **Svelte** components — with **zero custom API endpoints**, **dynamic locale switching**, and **native SSR hydration**. Traditionally, localized Inertia applications face a frustrating dilemma: either manually pass translation arrays via `Inertia::render()` props on every controller, expose asynchronous REST endpoints that cause layout shifts (FOUC), or maintain duplicate translation files in JavaScript that constantly fall out of sync with Laravel's validation messages. **Laravel Lang Sync Inertia** eliminates that friction completely by treating Laravel as your **single source of truth** and automatically delivering translation dictionaries directly through Inertia's shared page props. ## The Localization Bridge Inertia acts as the glue connecting Laravel with your modern frontend frameworks. **Laravel Lang Sync Inertia** is the complementary glue for your translations. Instead of manually passing translation arrays in every controller, exposing custom REST endpoints, or duplicating translation files across PHP and JavaScript, this package seamlessly connects your existing language files to your client components.
🎯

Single Source of Truth

Manage all translations in standard Laravel lang/{locale} files. Never maintain duplicate dictionaries in JavaScript.

⚡

Zero API Overhead

Translations pass directly through Inertia's shared page props. No Axios calls, loading spinners, or runtime delays.

💬

Familiar Helper API

Use standard __() and trans() helpers in Vue, React, and Svelte with full placeholder support.

🚀

Full SSR Compatibility

Translations are pre-hydrated on the server, eliminating layout shifts and flashes of untranslated text (FOUC).

## How It Works The architecture follows a simple 4-step pipeline from your backend language files to your frontend components:
1

Define Language Files

Write standard Laravel translation files in lang/{locale}/app.php.

2

Sync in Controller

Call syncLangFiles() in controllers.

3

Inertia Prop Share

Translations are attached automatically to page.props.lang.

4

Render in Frontend

Use __() or trans() in Vue, React, or Svelte components.

## Compatibility and Support **Laravel Lang Sync Inertia** follows semantic versioning and actively supports modern Laravel and Inertia stacks: | Ecosystem / Framework | Supported Versions | Status | | :-------------------- | :------------------------------ | :------------------------------------------------------------------------------- | | **Laravel** | 10.x, 11.x, 12.x, 13.x | Active Support | | **Inertia.js** | 1.x, 2.x, 3.x | Active Support | | **Vue** | 3.x (Composition and Options API) | Active Support | | **React** | 18.x, 19.x | Active Support | | **Svelte** | 4.x, 5.x | Active Support | | **PHP** | 8.1, 8.2, 8.3, 8.4+ | Active Support | ## Next Steps Ready to get started with **Laravel Lang Sync Inertia**? Follow the guides below:
Installation →
Install the Composer and npm packages in under two minutes.
Configuration →
Customize default locales, language directories, and middleware behavior.
Laravel Usage →
Learn how to call helper functions and register global Inertia middleware.
Frontend Guides →
Explore step-by-step guides for Vue, React, and Svelte components.