R.swift
R.swift copied to clipboard
Global language change in R.Swift
Yesterday I change all my strings(~1k) to R.string in my app. In my app I can change language of app. But after change strings to R.string - change language in app not working. I need global change of locale in R.swift. How I can do it?
I found #553 - but there is about preferredLanguages, not about dynamically global change locale.
I run sed to replace NSLocalizedString to MyLocalizedString. Something like this
"$PODS_ROOT/R.swift/rswift" generate --accessLevel internal "$NEW_FILE"
/usr/bin/sed -i 's/NSLocalizedString/MyLocalizedString/g' "${NEW_FILE}"
I think option to select localization function will be good idea
+1