
Wiki documentation for Kotlin users
CmdrNorthpaw opened this issue ยท 0 comments
I've been using Conrad in Kotlin development for a while, and I've found that it needs a few tweaks to work properly with the language. I'd like to propose a wiki article outlining those tweaks, so that Kotlin users can get started with this (very nice) config library without needing to figure it out for themselves. I've linked a draft which you can look over and use in the wiki, or perhaps you'd like to write an article yourself.
The changes I've found are needed so far:
- The Kotlin entrypoint adapter needs to be used when defining a config adapter in
fabric.mod.json
. It's technically still possible to use the library without doing that, but you have to use a class and a companion object which is a lot more clunky. - Any config values need to be annotated with
@JvmField
, because if you don't do this Kotlin will create a static getter for them instead of just exposing the property.