Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Blank React Starter Kit

Blank React Starter Kit Laravel Package

laravel/blank-react-starter-kit

Minimal Laravel + React starter kit using Inertia, Vite, TypeScript, and Tailwind. Build SPA-like React apps with classic Laravel routing and controllers. No authentication scaffolding included—start from a clean, modern baseline.

View on GitHub
Deep Wiki
Context7

At a glance

Frequently asked questions about Blank React Starter Kit
What Laravel versions does this starter kit support?
The Laravel React Starter Kit is officially designed for Laravel 10+. It leverages modern features like Vite and Inertia.js, which require PHP 8.1+ and Laravel’s latest conventions. Always check the [official docs](https://laravel.com/docs/starter-kits) for version-specific updates, as compatibility may shift with minor Laravel releases.
How do I install and set up this package in an existing Laravel project?
Run `composer require laravel/blank-react-starter-kit` in your Laravel project’s root. Then execute `npm install` and `npm run dev` to compile assets. The starter kit preserves Laravel’s existing structure, so no database migrations or config changes are needed unless you’re adding React-specific routes or middleware. Follow the [Laravel docs](https://laravel.com/docs/starter-kits) for post-installation steps.
Does this starter kit include authentication (e.g., Sanctum, Breeze, or Jetstream)?
No, this starter kit intentionally excludes authentication scaffolding to keep the base lightweight. You’ll need to integrate Laravel Breeze, Sanctum, or another auth package separately. The [Laravel docs](https://laravel.com/docs/authentication) provide guides for adding auth to Inertia.js apps, including server-side session handling or token-based APIs.
Can I use this starter kit for a full single-page application (SPA) instead of a hybrid Laravel/React app?
While Inertia.js enables SPA-like behavior, this starter kit is optimized for hybrid architectures where Laravel handles backend logic and React enhances interactivity. For a full SPA (e.g., client-side routing, Next.js-like features), consider alternatives like Next.js with Laravel as an API backend or a custom Vite + React setup without Inertia.
How does Vite integration work with Laravel’s Blade templates? Will I need to disable Blade?
Vite and Blade coexist seamlessly in this starter kit. Vite handles React/TypeScript/Tailwind assets, while Blade remains for server-side rendering (e.g., login pages, emails). No Blade changes are required. However, avoid mixing Blade and React logic in the same view—use Inertia’s page components for React-driven UI. Vite’s HMR works independently of Blade’s caching.
Is TypeScript mandatory? Can I use plain JavaScript instead?
TypeScript is pre-configured for type safety and scalability, but you can revert to JavaScript by renaming files (e.g., `*.ts` → `*.js`) and updating `tsconfig.json` to target `lib.esnext`. However, this may void some Inertia.js TypeScript-specific optimizations. The starter kit assumes TypeScript adoption, so teams unfamiliar with it may face refactoring overhead.
How do I handle form submissions and validation between Laravel and React?
Use Inertia.js’s built-in form handling with Laravel’s validation. Submit forms via `useForm` from `@inertiajs/inertia-react`, which automatically serializes data to Laravel. Validation errors return as props to your React component. For complex forms, pair with Laravel’s Form Request validation or Zod schemas (if using Inertia’s latest features). Example: `useForm({ email: '', remember: false })`.
What testing tools are included, and how do I test React components with Laravel?
The starter kit includes Laravel’s PHPUnit for backend tests and Jest for React components (via `@testing-library/react`). Configure Jest by extending `vite.config.ts` and adding test scripts to `package.json`. For end-to-end testing, use Laravel Dusk or Cypress. Inertia.js simplifies testing by allowing you to mock server responses in React tests while reusing Laravel’s existing test helpers.
Are there performance concerns with Tailwind CSS in production?
Tailwind CSS is pre-configured with PurgeCSS (via Vite) to eliminate unused styles in production. However, heavy Tailwind usage without a design system or component library can bloat your CSS. Optimize by using `@apply` sparingly, adopting a CSS-in-JS solution for dynamic styles, or implementing a design token system. Monitor bundle size with `npm run build -- --analyze` to identify Tailwind-related bloat.
What alternatives exist if I need micro-frontends or a separate React repo?
For micro-frontends, consider ejecting the React/Vite setup into a standalone repo and using Laravel’s API routes with a custom proxy (e.g., Nginx or Vite’s `proxy` option). Alternatives include Laravel’s API resources paired with a Next.js or Create React App frontend, or tools like Module Federation for advanced micro-frontend architectures. This starter kit’s monolithic structure isn’t ideal for these use cases.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport