0040-laravel-event-driven-architecture

Community

Build decoupled Laravel event workflows

AuthorMrJmpl3
Version1.0.0
Installs0

System Documentation

What problem does it solve?

It reduces tightly coupled application code by routing side effects (notifications, PDFs, indexing, auditing) through Laravel events and listeners instead of direct calls scattered across services.

Core Features & Use Cases

  • Event + Listener Structure: Use typed event objects (data carriers) and single-responsibility listener classes to keep domain logic clean.
  • Queued & Safer Dispatching: Run slow listeners asynchronously with ShouldQueue, optionally conditionally with shouldQueue(), and protect data consistency with ShouldQueueAfterCommit or $afterCommit = true.
  • Discovery, Subscribers, and Model Lifecycle Hooks: Rely on Laravel listener auto-discovery, use event subscribers for grouped handling, and dispatch events from model observers for lifecycle-driven workflows.

Quick Start

Ask an AI to generate a Laravel event, register an auto-discovered listener that sends a notification, and modify it to run queued after the database transaction commits.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: 0040-laravel-event-driven-architecture
Download link: https://github.com/MrJmpl3/codex_____data_____configuration/archive/main.zip#0040-laravel-event-driven-architecture

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.