I'm working on a library (an android library to be...
# getting-started
c
I'm working on a library (an android library to be exact). if I update that lib to kotlin 2.2.20, would all of my consumers be forced to use that new version? like. is it better for me to use an old version?
e
unless you do some specific work otherwise, it means your library metadata will be 2.2, and you will have a dependency on kotlin-stdlib:2.2.20, which means any consumers below kotlin 2.1 will break
IMO: libraries should use as old versions as they can reasonably tolerate, to be usable in the widest range of applications
c
cool. so app version i can be more bleeding edge. and libraries i will be more conservative. thank you!
t
IMO depends on your consumers relativity to you a ton too. I'd probably stay on older versions for stuff that is consumed by 3rd parties, but for internal libraries I upgrade aggressively and just tell coworkers to stop being so lazy about updating given they have to be 2 versions or more behind for it to become a real problem. at that point they can just stay on an older library version until they are ready to update.