[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-7372":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":17,"stars30d":17,"stars90d":16,"forks30d":16,"starsTrendScore":18,"compositeScore":19,"rankGlobal":10,"rankLanguage":10,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":21,"hasPages":23,"topics":24,"createdAt":10,"pushedAt":10,"updatedAt":37,"readmeContent":38,"aiSummary":39,"trendingCount":16,"starSnapshotCount":16,"syncStatus":17,"lastSyncTime":40,"discoverSource":41},7372,"Kodein","kosi-libs\u002FKodein","kosi-libs","Painless Kotlin Dependency Injection","https:\u002F\u002Fkosi-libs.org\u002Fkodein",null,"Kotlin",3330,177,46,8,0,2,1,59.95,"MIT License",false,"main",true,[25,26,27,28,29,30,31,32,33,34,35,36],"android","compose","compose-desktop","injection","kodein","kodein-di","kodein-framework","kotlin","kotlin-dependency-injection","kotlin-multiplatform","ktor","tornadofx","2026-06-12 04:00:33","[![Maven Central](https:\u002F\u002Fimg.shields.io\u002Fmaven-central\u002Fv\u002Forg.kodein.di\u002Fkodein-di)](https:\u002F\u002Fmvnrepository.com\u002Fartifact\u002Forg.kodein.di\u002Fkodein-di)\n[![Kotlin](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FKotlin-1.9.21-blue.svg?style=flat&logo=kotlin)](https:\u002F\u002Fkotlinlang.org)\n![Github Actions](https:\u002F\u002Fgithub.com\u002Fkosi-libs\u002FKodein\u002Factions\u002Fworkflows\u002Fsnapshot.yml\u002Fbadge.svg)\n[![MIT License](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Flicense-MIT-green.svg)](https:\u002F\u002Fgithub.com\u002Fkosi-libs\u002FKodein\u002Fblob\u002Fmaster\u002FLICENSE.txt)\n[![Slack channel](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FChat-Slack-green.svg?style=flat&logo=slack)](https:\u002F\u002Fkotlinlang.slack.com\u002Fmessages\u002Fkodein\u002F)\n\nKOtlin DEpendency INjection\n===========================\n\n**_KODEIN_** is a straightforward and yet very useful dependency retrieval container. it is effortless to use and configure.\n\n**_KODEIN_** works on all Kotlin Multiplatform targets:\n\n- JVM \u002F Android.\n- all Native platforms (iOS, macOS, Linux, Windows, WebAssembly).\n- Javascript \u002F WasmJs.\n\n**_KODEIN_** allows you to:\n\n- Lazily instantiate your dependencies when needed\n- Stop caring about dependency initialization order\n- Bind classes or interfaces to their instance or provider\n- Debug your dependency bindings and recursions\n\n**_KODEIN_** provides extensions to be integrable into:\n\n- [Android](https:\u002F\u002Fdeveloper.android.com\u002F)\n- [Compose (Android \u002F Desktop \u002F Web)](https:\u002F\u002Fkosi-libs.org\u002Fkodein\u002F7.22\u002Fframework\u002Fcompose.html)\n- [Ktor](https:\u002F\u002Fktor.io\u002F)\n\nAn example is always better than a thousand words:\n\n```kotlin\nval di = DI {\n    bindProvider\u003CDice> { RandomDice(0, 5) }\n    bindSingleton\u003CDataSource> { SqliteDS.open(\"path\u002Fto\u002Ffile\") }\n}\n\nclass Controller(private di: DI) {\n    private val ds: DataSource by di.instance()\n}\n```\n\n**_KODEIN_** is a good choice because:\n\n- It proposes a very simple and readable declarative DSL\n- It is not subject to type erasure (as Java is)\n- It integrates nicely with Android\n- It proposes a very kotlin-esque idiomatic API\n- It is fast and optimized (makes extensive use of `inline`)\n\nInstallation\n---------\n\nKodein is available on Maven Central.\n\n```kotlin\nrepositories {\n    mavenCentral()\n}\n```\n\n```kotlin\nkotlin {\n    sourceSets {\n        commonMain {\n            dependencies {\n                implementation(\"org.kodein.di:kodein-di:{version}\")\n            }\n        }\n    }\n}\n```\n\n**_KODEIN_** 7+ is the current major version, but documentation is available for previous versions.\n\n**[Kodein documentation](https:\u002F\u002Fkosi-libs.org\u002Fkodein\u002F)**\n\n\nKotlin & JVM compatibility\n---------\n\n| Kodein | Kotlin |   JDK   |\n|:------:|:------:|:-------:|\n|  7.27  | 2.2.+  | min 17  |\n|  7.26  | 2.1.+  | min 17  |\n|  7.23  | 2.0.+  | min 17  |\n|  7.22  | 2.0.+  | min 11  |\n|  7.21  | 1.9.+  | min 1.8 |\n|  7.20  | 1.8.10 | min 1.8 |\n|  7.19  | 1.8.10 | min 1.8 |\n|  7.18  | 1.8.0  | min 1.8 |\n|  7.17  | 1.8.0  | min 1.8 |\n\n> Full table can be found [here](https:\u002F\u002Fkosi-libs.org\u002Fkodein\u002F7.22\u002Fcore\u002Fplatform-and-genericity.html)\n\nSupport\n-------\n\nSupport is held in the [Kodein Slack channel](https:\u002F\u002Fkotlinlang.slack.com\u002Fmessages\u002Fkodein\u002F)\n(you can get an invitation to the Kotlin Slack [here](https:\u002F\u002Fslack.kotlinlang.org\u002F)).\n\n[\u002F\u002F]: # (Testimonies)\n\n[\u002F\u002F]: # (-----------)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (&nbsp;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (> At [Collokia]&#40;https:\u002F\u002Fwww.collokia.com\u002F&#41; we use Kodein in all of our backend service infrastructure and all modules in those services are loosely coupled through injection with Kodein.)\n\n[\u002F\u002F]: # (> It allows us to have nice module independence, and to opt-out of injection during testing or build separate modules in support of testing.  )\n\n[\u002F\u002F]: # (> It is a key component and building block in our architecture.  )\n\n[\u002F\u002F]: # (> -- [Jayson Minard]&#40;https:\u002F\u002Fgithub.com\u002Fapatrida&#41;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (&nbsp;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (> At [Moovel Group GmbH]&#40;https:\u002F\u002Fwww.moovel.com\u002Fde\u002Fen&#41;, we have successfully used the wonderful Kodein library into in [this Android app]&#40;https:\u002F\u002Fplay.google.com\u002Fstore\u002Fapps\u002Fdetails?id=com.daimler.moovel.android&#41;.)\n\n[\u002F\u002F]: # (> As we improved it, we found Kodein to be much more useful than Dagger2 as it simplified our code throughout.  )\n\n[\u002F\u002F]: # (> Kodein is in my view, much easier to understand, doesn't have that nasty ceremony, and has really nice debug messages.  )\n\n[\u002F\u002F]: # (> We are also working now on other projects where we are using Kodein as well.  )\n\n[\u002F\u002F]: # (> -- [Sorin Albu-Irimies]&#40;https:\u002F\u002Fgithub.com\u002Fsorinirimies&#41;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (&nbsp;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (> Kodein has been instrumental in moving our entire production application to Kotlin at [InSite Applications]&#40;https:\u002F\u002Finsiteapplications.com&#41;. It uses standard Kotlin idioms and features for ultimate clarity and simplicity. It was clear to us from the beginning that Kodein would be our DI solution. Our devs love it so much that they've transitioned to using it in their personal apps, both Java and Kotlin!  )\n\n[\u002F\u002F]: # (> -- [Eliezer Graber]&#40;https:\u002F\u002Fgithub.com\u002Feygraber&#41;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (&nbsp;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (> At [Compsoft Creative]&#40;https:\u002F\u002Fwww.compsoft.co.uk&#41;, Kodein is central our new Kotlin based app architecture, giving us a solid underpinning to all apps we develop and allowing a simple yet powerful way to de-couple our services with a library that is lightweight and perfect for mobile apps.  )\n\n[\u002F\u002F]: # (> -- [Daniel Payne]&#40;https:\u002F\u002Fgithub.com\u002FCompsoftCreative&#41;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (&nbsp;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (> Kodein is used in [the android app of the OhelShem school]&#40;https:\u002F\u002Fgithub.com\u002FOhelShem\u002Fandroid&#41;.  )\n\n[\u002F\u002F]: # (> -- [Yoav Sternberg]&#40;https:\u002F\u002Fgithub.com\u002Fyoavst&#41;&nbsp;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (&nbsp;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (> Kodein was created at [Dental Monitoring]&#40;https:\u002F\u002Fdental-monitoring.com\u002F&#41; with the opinion that Dagger2 is way too verbose and complex.)\n\n[\u002F\u002F]: # (> It is now used in almost all our projects: the server, the internal production software & the Android application.  )\n\n[\u002F\u002F]: # (> Kodein is very easy to use and set up: it allows our team to easily share code and patterns, as well as quickly bootstrapping new ideas.  )\n\n[\u002F\u002F]: # (> -- [Salomon Brys]&#40;https:\u002F\u002Fgithub.com\u002FSalomonBrys&#41;)\n\n[\u002F\u002F]: # ()\n[\u002F\u002F]: # (&nbsp;)\n\nIf you are using KODEIN, please [let us know](mailto:contact@kodein.net)!\n\n## Supported by\n\n[![JetBrains logo.](https:\u002F\u002Fresources.jetbrains.com\u002Fstorage\u002Fproducts\u002Fcompany\u002Fbrand\u002Flogos\u002Fjetbrains.svg)](https:\u002F\u002Fjb.gg\u002FOpenSourceSupport)","Kodein 是一个用于 Kotlin 的依赖注入框架，旨在简化依赖管理和实例化过程。其核心功能包括懒加载依赖、无视初始化顺序绑定类或接口到其实例或提供者，并支持调试依赖关系和递归。Kodein 支持 Kotlin 多平台项目，涵盖 JVM\u002FAndroid、所有原生平台（iOS, macOS, Linux, Windows, WebAssembly）以及 JavaScript\u002FWasmJs 环境。此外，它还提供了与 Android、Compose 和 Ktor 的集成扩展。Kodein 采用简洁易读的声明式 DSL，避免了类型擦除问题，并且拥有高度优化的性能表现。适用于需要在 Kotlin 项目中实现灵活而高效的依赖管理场景。","2026-06-11 03:11:59","top_language"]