We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
we retrieve services by string key, which is inherently type unsafe
$foo = $container->get('my.service'); // what type is $foo?
It would be good to migrate to PSR-style where class names are used:
$foo = $container->get(Foo::class); // it is a Foo
An intermediate step might be to add an (optional?) type check parameter
$foo = $container->get('my.service', Foo::class); // error if the registered service is not Foo
The text was updated successfully, but these errors were encountered:
No branches or pull requests
we retrieve services by string key, which is inherently type unsafe
It would be good to migrate to PSR-style where class names are used:
An intermediate step might be to add an (optional?) type check parameter
The text was updated successfully, but these errors were encountered: