mastodon.social is one of the many independent Mastodon servers you can use to participate in the fediverse.
The original server operated by the Mastodon gGmbH non-profit

Administered by:

Server stats:

352K
active users

Daniel Saidi

Did you know that the new Xcode Strings catalog lets you vary translations by device? This is such a nice feature 🤩

@danielsaidi cc/ @jaanus 🎗️A few of the shared strings in @tact would benefit from this approach.

Not sure how hard it would be to set this up, but worth exploring.

@infotexture @jaanus @tact It’s suuuper convenient and you can even convert existing strings file to a catalog, but I’m sure there are many challenges for big already localized apps. Perhaps a piecemeal approach?

@danielsaidi @infotexture @tact Thank you for pointing this out. I have some projects where this would indeed be useful. Haven’t gotten around to experimenting with this yet, but this ability to vary the strings by platform motivates me to look into this soon.

One question I have is, how do string catalogs work if code is split across modules (SPM package targets)? Can UI code in modules pick up the strings from the catalog? Currently I have separate strings files in the modules.

@jaanus @infotexture @tact I have string catalogs in an SPM package, as well as in an app. The SPM package must define .module as bundle for the strings to be translated in the main app. I guess if you expose the module bundle to the app, they could use strings from the SPM package too?