Moe
03/26/2025, 1:35 AMCompositionLocalt("key")LocalizationProviderRok Oblak
03/26/2025, 5:08 AMCTAStrings(val submit: String)Strings(val one: String, val two: String, val three: (Int) -> String, cta: CTAStrings)val LangAStrings = Strings(...)val LangBStrings = Strings(...)LocalStrings.current.twoLocalStrings.current.cta.submitgeneralctaerrorsval EN_Translations: Translations = Translations(
      general = General(
        one = "one_EN",
        two = "two_EN"
      ),
      errors = Errors(
        test1 = "test1EN",
        test2 = "test2EN"
      ),
      cta = Cta(
        submit = "submit_EN",
        test = "test_EN"
      )
    )Konstantin Tskhovrebov
03/26/2025, 10:00 AMian.shaun.thomas
03/26/2025, 3:37 PMMoe
03/26/2025, 5:17 PMdata classCompositionLocalsealed interfacest("key")✅ No-setup-needed
✅ Works out-of-the-box
✅ Easy to drop into any KMP-WASM projectThe is definitely room for improvement here, which i do plan on doing in the near future, however I honestly made this so i can use it in my own projects, which was the least amount of work that could be done that suits what I needed in regards to scaling versus simplicity. So in short, you’re right, this won’t scale as cleanly for large apps today, but it’s a great “day-one” solution, and hopefully a nice starting point for teams who just want to localize a WASM app without wiring up anything complex.
Moe
03/26/2025, 5:19 PMDatePickerTimePickerSnackbarPlatformLocaleandroidx.compose.material3.LocalStringsCompose LocalizerMoe
03/26/2025, 5:20 PM