compose-remember-preference icon indicating copy to clipboard operation
compose-remember-preference copied to clipboard

Publish jar for desktop app support

Open hakanai opened this issue 1 year ago • 2 comments

If I try to pull in this dependency for a desktop application, I get:

   > Could not resolve dev.burnoo:compose-remember-preference:1.0.2.
     Required by:
         project :
      > No matching variant of dev.burnoo:compose-remember-preference:1.0.2 was found. The consumer was configured to find a library for use during compile-time, compatible with Java 17, packaged as a jar, preferably optimized for standard JVMs, and its dependencies declared externally, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'jvm' but:
          - Variant 'releaseVariantReleaseApiPublication' capability dev.burnoo:compose-remember-preference:1.0.2 declares a library for use during compile-time, and its dependencies declared externally:

etc.

This may be waiting for JetBrains or whoever to publish the desktop version of the dependency.

hakanai avatar Jan 18 '24 23:01 hakanai

This library is Android only 😕

To make it work with desktop apps, the library would have to be migrated from Android only DataStore to KMM library for storing data, for example: https://github.com/russhwolf/multiplatform-settings

burnoo avatar Jan 19 '24 15:01 burnoo

It would be possible to create a very similar library with Compose Multiplatform support - I've created a proposal: https://github.com/russhwolf/multiplatform-settings/issues/196

burnoo avatar Jun 22 '24 15:06 burnoo

@hakanai I've just released library that you are looking for: https://github.com/burnoo/compose-remember-setting

burnoo avatar Aug 07 '24 15:08 burnoo