← Back to list

scaffold-middleware
by iurygdeoliveira
Repositorio destinado a fornecer um kit inicial para desenvolvimento de SaaS usando laravel e filament
⭐ 29🍴 12📅 Jan 20, 2026
SKILL.md
name: scaffold-middleware description: Standardizes Middleware creation and registration for Laravel 11/12 (bootstrap/app.php).
Laravel Middleware Pattern Skill
Use this skill when implementing request filtering or modification logic.
Rules
1. Modern Registration (Laravel 12)
- Do NOT look for
app/Http/Kernel.php(it is gone). - Register middleware in
bootstrap/app.phpusing the->withMiddleware()callback. - Use
append()for global oralias()for route-specific.
->withMiddleware(function (Middleware $middleware) {
$middleware->append(EnsureTokenIsValid::class);
$middleware->alias([
'admin' => EnsureUserIsAdmin::class,
]);
})
2. Structure
- Implement the
handlemethod with proper typing.
public function handle(Request $request, Closure $next): Response
{
if (...) {
return redirect('/home');
}
return $next($request);
}
Score
Total Score
80/100
Based on repository quality metrics
✓SKILL.md
SKILL.mdファイルが含まれている
+20
✓LICENSE
ライセンスが設定されている
+10
✓説明文
100文字以上の説明がある
+10
○人気
GitHub Stars 100以上
0/15
✓最近の活動
1ヶ月以内に更新
+10
✓フォーク
10回以上フォークされている
+5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
✓タグ
1つ以上のタグが設定されている
+5
Reviews
💬
Reviews coming soon

