conference-app-2021 icon indicating copy to clipboard operation
conference-app-2021 copied to clipboard

Logger solution for Kotlin MPP

Open takahirom opened this issue 3 years ago • 2 comments

Kind (Required)

  • Improvement

Overview (Required)

  • We tried arbor but it does not support Kotlin Native

I want a library that has the following elements:

  • Interface that does not need to declare fields etc. every time like Timber
  • Can be flexibly sent to crashlytics etc. like Timber
  • It is compatible with recent Kotlin versions.
  • Supports kotlin native

Links

takahirom avatar Mar 09 '21 00:03 takahirom

@takahirom How about AAKira/Napier ? This logger library is inspired by Timber which you desire.

This features

  • sending to Crashlytics
  • looks simple interface (to me)
  • again, inspired by Timber

If this is not suit for this project, it may be good to see AAKira/Kotlin-Multiplatform-Libraries to look for another suitable library.

daichikuwa0618 avatar Apr 09 '21 10:04 daichikuwa0618

Thank you for your suggestion. I was worried that there was no update recently. 😅 However, this library uses Kotlin 1.4.0, and ABI compatibility version is 1.4.1, so there seems to be no problem. https://github.com/JetBrains/kotlin/blob/v1.4.0/compiler/util-klib/src/org/jetbrains/kotlin/library/KotlinAbiVersion.kt#L34 There is no problem from the ABI side, but there is a risk that code highlighting will not work on iOS if it does not support the hierarchical structure. https://kotlinlang.org/docs/mpp-share-on-platforms.html#use-target-shortcuts image

However, regarding the hierarchical structure, other libraries are the same, so it seems that it is okay to include it. 👍

takahirom avatar Apr 14 '21 01:04 takahirom