Closed arkivanov closed 3 months ago
The instance-keeper
module has introduced new functions (provide
, provideSimple
, providing
, providingSimple
) in InstanceKeeperExtKt
for obtaining or creating instances, marking a shift from the older getOrCreate
methods. These changes, aimed at enhancing clarity and consistency in method naming, also include lazy variants for deferred instance creation. The update affects both the Android and JVM APIs and modifies the common and test code to align with the new naming convention.
Files | Change Summary |
---|---|
instance-keeper/api/.../instance-keeper.api |
Added provide , provideSimple , providing , providingSimple functions. |
instance-keeper/src/commonMain/.../InstanceKeeperExt.kt |
Deprecated getOrCreate , introduced provide and lazy variants. |
instance-keeper/src/commonTest/.../InstanceKeeperExtTest.kt |
Replaced getOrCreate with provide in tests. |
instance-keeper/src/androidUnitTest/.../AndroidInstanceKeeperTest.kt |
Updated calls from getOrCreate to provide for instance creation in tests. |
🐇✨
In the realm of code, where instances dwell,
A new path unfolds, with tales to tell.
provide
andproviding
, simple and clear,
Out with the old, the new is here.
Through tests and tales, our journey's set,
A hop, a skip, in code, we met.
🌟🐾
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Summary by CodeRabbit
InstanceKeeper
module, enhancing flexibility and usability.getOrCreate
functions in favor of new, more intuitively namedprovide
functions, including lazy variants for deferred instance creation.