Skip to content

Configuration example for controller that extends AbstractController if autoconfigure/autowire is not used (e.g. in a bundle) #16579

Closed
@AndreasA

Description

@AndreasA

It would be nice if you added a configuration example to the docs that defines how a controller can be configured correctly as service, if it extends the abstractcontroller without autowire/autoconfigure.

if I understand it correctly, this would be the correct configuration:

            <tag name="container.service_subscriber" />
            <tag name="controller.service_arguments" />
            <call method="setContainer">
                <argument type="service" id="Psr\Container\ContainerInterface" />
 Show conversation
            </call>

Metadata

Metadata

Assignees

No one assigned

    Labels

    hasPRA Pull Request has already been submitted for this issue.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions