Dynamic Observer
  • Introduction
  • Getting Started
    • Installation
    • Requirements
  • Usage
    • Basic Usage
    • Custom Observers
    • Multiple Observers
  • Guides
    • Available Methods
Powered by GitBook
On this page
  • Using Composer
  • Verification
  1. Getting Started

Installation

PreviousIntroductionNextRequirements

Last updated 4 months ago

Getting started with Laravel Dynamic Observer is straightforward. Follow these simple steps to add the package to your Laravel project.

Using Composer

composer require waad/laravel-dynamic-observer

That's it! The package will automatically register itself with Laravel.

Verification

To verify the installation, you can create a simple model with the HasObserver trait:

<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Waad\Observer\HasObserver;

class Post extends Model
{
    use HasObserver;
}

If no errors occur when accessing your model, the package is installed correctly.

github-laravel-dynamic-observer