Localization is a framework for in-app language changes, providing reactive API so that the app can be translated in real time.
Basic
label.l10n.text.bind(.pure("Hello"))
languageButton.l10n.title(for: .normal).bind(key: "Language")
Operations
let localizer = Localizer.pure("Part 1")
.combine(.pure("Part 2"))
.map { $0 + " " + $1 }
.map { NSAttributedString(string: $0, attributes: [.foregroundColor: UIColor.systemPink]) }
label.l10n.attributedText.bind(localizer)
Octree, [email protected]
Localization is available under the MIT license. See the LICENSE file for more info.
link |
Stars: 3 |
Last commit: 2 weeks ago |
Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics