https://github.com/michaelhenry/localizr.swift
Simplified and automated Localization process library in IOS. Please check https://github.com/michaelhenry/Localizr for more info.
https://github.com/michaelhenry/localizr.swift
ios language locale localization swift
Last synced: 21 days ago
JSON representation
Simplified and automated Localization process library in IOS. Please check https://github.com/michaelhenry/Localizr for more info.
- Host: GitHub
- URL: https://github.com/michaelhenry/localizr.swift
- Owner: michaelhenry
- License: mit
- Created: 2018-05-28T17:50:04.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2018-09-08T03:26:07.000Z (over 6 years ago)
- Last Synced: 2025-04-13T07:10:00.728Z (21 days ago)
- Topics: ios, language, locale, localization, swift
- Language: Swift
- Homepage:
- Size: 339 KB
- Stars: 19
- Watchers: 3
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Localizr.swift
[](https://travis-ci.org/michaelhenry/Localizr.swift)
[](https://cocoapods.org/pods/Localizr.swift)
[](https://cocoapods.org/pods/Localizr.swift)
[](https://cocoapods.org/pods/Localizr.swift)
## Example
To run the example project, clone the repo, and run `pod install` from the Example directory first.
I did not write anything to all **Localizable.strings** files that can be found in [Locales folder](Example/Localizr-iOS/Locales) so that you could see how it was generated and synced using the [Localizr server](https://github.com/michaelhenry/localizr) when you start to run this example project.
You can check the Project's **Build Phases > Run Script** and see how I CURL(ed) the data from the [Localizr server](https://github.com/michaelhenry/localizr). I do recommend to do this using CI for adhoc build distribution(not development/appstore/testflight build distribution). You should freeze the localization files during testflight build distribution or atleast enable the snapshot capability from the Localizr server.
## Requirements
## Installation
Localizr.swift is available through [CocoaPods](https://cocoapods.org). To install
it, simply add the following line to your Podfile:```ruby
pod 'Localizr.swift'
```## How to use it.
```swift
import Localizr_swift```
To show all supported localization
```swift
Localizr.supportedLocales()```
To update the current localization
```swift
Localizr.update(locale: "en")```
To get the current localization
```swift
Localizr.currentLocale()```
To show the localized value
```swift
"HELLO_WORLD".localized()```
## Author
Michael Henry Pantaleon, [email protected]
## License
Localizr.swift is available under the MIT license. See the LICENSE file for more info.