Skip to content

Instantly share code, notes, and snippets.

@romainbsl
Created June 1, 2020 14:12
Show Gist options
  • Save romainbsl/f633115e55ec97e2ee44f11ce40cf201 to your computer and use it in GitHub Desktop.
Save romainbsl/f633115e55ec97e2ee44f11ce40cf201 to your computer and use it in GitHub Desktop.
// Bindings
val kodeinContainer = Kodein {
bind() from singleton { MyController() }
constant("creator") with ("Salomon BRYS")
constant("maintainer") with ("Romain BOISSELLE")
}
// Kodein Aware application
class DemoApplication(override val kodein: Kodein)
: Application(), KodeinAware {
// ...
}
// "Usage"
fun main() { DemoApplication(kodeinContainer) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment