@yiiliveext Simplify the configuration by creating CacheProvider, LoogerProvider, WebViewProvider, MailerProvider, now config common and web are short.
@yiiliveext Simplify the configuration by creating CacheProvider, LoogerProvider, WebViewProvider, MailerProvider, now config common and web are short.
There are only two things that could go against it, one to pass parameters, and the second must be registered in order, but at least I prefer it, before having a very long configuration.
There are only two things that could go against it, one to pass parameters, and the second must be registered in order, but at least I prefer it, before having a very long configuration.
If you want to disable|enable a package without removing you have to do it with a parameter like ['your-package.enabled' => true]. See the debugger package.
Could you tell me which ones, because I tested them a lot and it works very well, in fact your work with service providers is excellent.
Now everything is ok, but you can try to use some service in the register method of the package provider that is registering by the main app service provider.
final class MyProvider extends ServiceProvider { public function register(Container $container): void { $eventDispatcher = $container->get(EventDispatcherInterface); } }