Closed KSVQ closed 7 years ago
Hello,
It looks like you forgot to autoload your modules via composer.
As per the documentation in your composer.json
file:
{
"autoload": {
"psr-4": {
"App\\": "app/",
"Modules\\": "Modules/"
}
}
}
You're free to use any module structure as you want. There are no limitations as it's autoloaded via psr-4.
Hmh,, That was true,, I added it (default installation composer? correct?),,, Now I get this.
[Symfony\Component\Debug\Exception\FatalThrowableError] Class 'Modular' not found
Can I delete a module? ( App1 )
That isn't something from this package, so maybe something you bound in the IoC.
Don't forget to run composer dump-autoload
after adding the modules folder to PSR-4 autoloader, so composer loads them.
Ok,, I won't try to patch this. I will run a fresh install and make sure I do everything again. I'll let you know how it goes.
Alright, so I went through both 5.3 and 5.4 and it all went through okay.
Is there a way to delete a Module (undeveloped) with Artisan and insure everything is removed correctly?
No, but I might add a command for this. Basically you just remove the module directory. Also note #150
I am researching a viable modular approach for a large app. For now I am testing and snooping around.
I installed on a brand new instance of Laravel 5.4. (followed instructions... I think) Created App1 module successfully
Tried to create multiple modules and got this... [Symfony\Component\Debug\Exception\FatalThrowableError] Class 'Modules\App1\Providers\App1ServiceProvider' not found Modules\App1\Providers\App1ServiceProvider DOES exist however. Something I missed??
Then I tried creating ONE instance,,, App2,,, and got the same error.
The file structure in the module is not consistent with Laravel version 5.4 (I see you say it was updated for 5.4)
Thanks!