https://kotlinlang.org logo
#compose
Title
# compose
z

zsperske

08/11/2022, 9:14 PM
Does
Locale
make sense as a composition local? How do y’all handle things like
uppercase()
which accepts a locale argument?
j

james

08/12/2022, 2:04 AM
IMO it would make sense as a custom CompositionLocal, but.. there’s already one for you 😄
LocalConfiguration.current.locales
will give you a list of Locales, and if it’s just the primary locale you’re after, then index 0 is the correct one
z

zsperske

08/12/2022, 2:23 AM
lol! i was relaying a teammate's question and didn't think to check… thanks!
4 Views