Skip to content
This repository has been archived by the owner on Dec 6, 2017. It is now read-only.

Every Binding result into a singleton #242

Open
Cedware opened this issue Jun 19, 2016 · 0 comments
Open

Every Binding result into a singleton #242

Cedware opened this issue Jun 19, 2016 · 0 comments

Comments

@Cedware
Copy link

Cedware commented Jun 19, 2016

When I use module.bind(MyDependency, toImplementation: MyDependency), I would expect allays the same instance of MyDependency.
But when I use: module.bind(MyDependency, toFactory: ()=>new MyDependency()), I would expect always a new instance of MyDependency when injector.get(MyDependency) is called.
Is there no possibility to bind a dependency as non singleton?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

1 participant