Development · Tip
One-Command shadcn/ui Page Install in Laravel
Add complete multi-file dashboard pages to Laravel via remote shadcn registries
This workflow demonstrates how to pull an entire production-ready page, including components and dependencies, directly into a Laravel Inertia/React project using the shadcn CLI. It leverages remote registries to scaffold complex views like product tables and filters in seconds. Once installed, integrating the layout requires only minor route definitions and wrapping the view in the application layout.
How it works
1. Run the dev server (`composer dev` in a Laravel app). 2. Run `pnpm dlx shadcn@latest add http://ui.shadcn.com/r/styles/new-york-v4/...` — the CLI checks the registry, installs dependencies, and creates files (e.g. resources/js/pages/products.tsx, resources/js/components/products-table.tsx, skipping identical files unless --overwrite). 3. Add the route (e.g. Route::get('settings', ...) in routes/settings.php or a products route). 4. Open the page in the browser; wrap it in `<AppLayout>` to get the sidebar nav. 5. End result: a Products page with nav, layout, tabs (All/In Stock/Low Stock/Archived), category and price filters, stock status badges, plus the starter kit's appearance settings with dark mode.
What it's for
- Scaffold complex data dashboard pages into a Laravel Inertia setup quickly
- Distribute and install modular multi-file components via custom or public shadcn registries
- Integrate pre-styled React UI tables and filters with Laravel starter kit layouts
Key points
- Uses `shadcn add <url>` to pull complete pages from remote registries
- Automatically resolves, installs, and places required UI components and dependencies
- Prevents overwriting identical existing project files unless explicitly specified
- Integrates directly into standard Laravel Inertia page directory structures (`resources/js/pages`)
- Pairs cleanly with existing Laravel starter kit navigation and AppLayout components
Pricing
Free
Details
- Type
- Tip
- Category
- Development
- Topic
- UI Scaffolding
- Open source
- Yes
- Platforms
- Command line
- For
- Full-stack Laravel developers using Inertia and React
- Tags
- laravel, shadcn, react, inertiajs, tailwind, scaffolding
Why it was saved
- @shadcn: Shows how remote registries can install whole multi-file features into a codebase, and how to integrate the result with Laravel's starter kit routes and AppLayout.
Related
Pre-built, responsive shadcn/ui blocks and layouts for React applications
Curated directory of crafted React, Tailwind, and shadcn UI components.
Free copy-paste React and CSS micro-interactions for modern web interfaces
Fullstack building blocks for AI apps installable with shadcn CLI
Curated shadcn/ui components, application blocks, animated elements, and MCP server.
Admin dashboard templates and UI blocks built with shadcn/ui and Tailwind
Updated