Last active
August 29, 2015 14:05
-
-
Save 0thernet/6b52315758e8631f9f9e to your computer and use it in GitHub Desktop.
Localize all the strings!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
infix operator | {} | |
func | (lhs: String, rhs: String) -> String { | |
return NSLocalizedString(lhs, comment: rhs) | |
} | |
postfix operator | {} | |
postfix func | (s: String) -> String { | |
return NSLocalizedString(s, comment: "") | |
} | |
let name = "Ben" | |
let title = "\(name)'s Profile"|"{User First Name}'s Profile" | |
let labelText = "Username"| |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment