nWidart / laravel-modules

Module Management In Laravel
https://docs.laravelmodules.com
MIT License
5.5k stars 954 forks source link

Integrate between modules #1885

Closed leen19971 closed 3 weeks ago

leen19971 commented 3 months ago

I want to know how to integrate between module for example if I need to create a model in module A but the model is located in module B .. what is the recommendation way for integration between modules.

dcblogdev commented 3 weeks ago

you can create models into a module ie php artisan make:make-model A B which would make a model called A in the module B.

If you want to keep things seperate you can fire events and listen to them in other modules.