Skip to content

Using Dagger to constructor inject Scenes that also receive saved state #143

@nickjvandyke

Description

@nickjvandyke

Is this possible? How would we tell Dagger what to inject for the Scene's savedState constructor parameter? For the time being I have switched to using Koin since with that I can locate the Scene's dependencies, and pass those and the savedState into the Scene's constructor manually.

To be clear, what I'm looking to be able to do is annotate my Scene with @Inject, and then either retrieve it through appComponent.getSomeSpecificScene() or let Dagger inject it into other classes. In both scenarios, the Scene is constructed entirely by Dagger.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions