initred/laravel-boost-guidelines
最新稳定版本:v1.3.0
Composer 安装命令:
composer require initred/laravel-boost-guidelines
包简介
Generate AI-friendly project guidelines for Laravel applications - Part of Laravel Boost ecosystem
README 文档
README
AI-powered coding guidelines for Laravel + Inertia React + Tailwind CSS v4 + shadcn/ui
Install best-practice guidelines for modern Laravel stack via a simple Artisan command. Works seamlessly with AI coding assistants like Claude, Cursor, and GitHub Copilot.
Features
- Inertia React v2 Forms - Modern
<Form>component anduseFormhook patterns - Tailwind CSS v4 Migration - CSS-first config, new utilities, deprecated class replacements
- shadcn/ui Integration - Proper error states, accessible form fields, button icon styling
- Wayfinder Support - Type-safe form actions with
.form()method - Interactive CLI - Select specific guidelines or install all at once
Quick Start
composer require initred/laravel-boost-guidelines --dev php artisan boost:guidelines --all
Installation
From Packagist (Recommended)
composer require initred/laravel-boost-guidelines --dev
The package will be auto-discovered by Laravel.
For Development
If you want to contribute or test local changes, add the package as a path repository:
{
"repositories": [
{
"type": "path",
"url": "../laravel-boost-guidelines"
}
]
}
Then install:
composer require initred/laravel-boost-guidelines:@dev --dev
After making changes to the package, update it:
composer update initred/laravel-boost-guidelines
Usage
Install Guidelines
# Interactive mode - select which guidelines to install php artisan boost:guidelines # Install all guidelines php artisan boost:guidelines --all # Install specific category only php artisan boost:guidelines --tailwindcss php artisan boost:guidelines --inertia-react # Install multiple categories php artisan boost:guidelines --tailwindcss --inertia-react # Force overwrite existing files php artisan boost:guidelines --force # Skip boost:update prompt after installation php artisan boost:guidelines --all --no-update # List available guidelines php artisan boost:guidelines --list
After Installation
Run Laravel Boost's update command to apply the guidelines:
php artisan boost:update
Automatic Installation (Optional)
Add to your project's composer.json scripts to automatically install guidelines on composer update:
{
"scripts": {
"post-update-cmd": [
"@php artisan boost:guidelines --all --force --no-update",
"@php artisan boost:update --ansi"
]
}
}
Available Guidelines
inertia-react/2/forms
Inertia v2 form handling guidelines (upgrade from v1's router.post pattern):
| Feature | Description |
|---|---|
<Form> Component |
Declarative form handling with built-in state management (v2.1+) |
useForm Hook |
For projects not yet on v2.1 |
| shadcn/ui Integration | Field components with proper error states (data-invalid, aria-invalid) |
| shadcn/ui Button | Icon styling best practices (no unnecessary mr-* or size-* classes) |
| Wayfinder Support | Type-safe form actions with .form() method |
| React 19 & Compiler | useRef argument requirements, ref callback syntax, auto-memoization |
wayfinder/core
Laravel Wayfinder integration for type-safe routing:
| Feature | Description |
|---|---|
| Named Imports | Tree-shakable controller method imports |
| Route Objects | Functions return { url, method } shaped objects |
| Form Support | .form() method for HTML form attributes |
| Query Parameters | query and mergeQuery options for URL params |
| Inertia Integration | Works with <Form> component and useForm hook |
tailwindcss/4/core
Tailwind CSS v4 migration guide:
| Before (v3) | After (v4) |
|---|---|
tailwind.config.js |
@theme directive in CSS |
@tailwind base/components/utilities |
@import "tailwindcss" |
bg-opacity-50 |
bg-black/50 |
flex-shrink-0 |
shrink-0 |
w-4 h-4 |
size-4 |
Running Tests
git clone https://github.com/initred/laravel-boost-guidelines.git cd laravel-boost-guidelines composer install composer test
Requirements
- PHP 8.2+
- Laravel 11.x or 12.x
- Laravel Boost
Contributing
Contributions are welcome! Please see CONTRIBUTING.md for details.
License
MIT License. See LICENSE for details.
initred/laravel-boost-guidelines 适用场景与选型建议
initred/laravel-boost-guidelines 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 238 次下载、GitHub Stars 达 0, 最近一次更新时间为 2026 年 01 月 12 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「laravel」 「react」 「guidelines」 「cursor」 「boost」 「ai」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 initred/laravel-boost-guidelines 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 initred/laravel-boost-guidelines 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 initred/laravel-boost-guidelines 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Spatie's Laravel & PHP coding guidelines for Laravel Boost
Async Reactive Postgres Driver for PHP (Non-blocking)
Spatie's coding guidelines as AI skills for Laravel Boost and skills.sh
Filament nestedset tree builder powered by kalnoy/nestedset with Filament v4 and v5 support
Wotzebra's Laravel & PHP coding guidelines for Laravel Boost
MCP Server for Yii2 applications - provides AI context and development tools via Model Context Protocol
统计信息
- 总下载量: 238
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 36
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2026-01-12