A quick & simple String extension to localize your application
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
LICENSE
README.md
String+Localizable.swift

README.md

Localizable

A quick & simple String extension to localize your application

Features

Fast and simple extention to String to replace NSLocalizedString and similar Apple functions.

How to Use

1. Add String+Localizable.swift on your project

2. Start localizing

Simple localization
"string.to.localize".localized
//  or
"string.to.localize".localized()
Get localization form a table
"string.to.localize".localized("TableName")
Comment localization
"string.to.localize".localized(comment: "This is the comment")
Pass arguments
"string.to.localize %@".localized(arguments: [12]) // Print: "string.to.localize 12"
Pass default value
"string.to.localize %@".localized(value: "No localization found")

Requirements

Current version is compatible with:

  • Swift 3.0+
  • iOS 9 or later