Created
February 7, 2017 14:47
-
-
Save Tibb/7aca787579cc0c9492aceb925e46eea4 to your computer and use it in GitHub Desktop.
Swift extension to ease NSLocalizedString
This file contains 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
extension String { | |
var localized : String { | |
return NSLocalizedString(self, comment: "") | |
} | |
} | |
//Usage: label.text = "myString".localized |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment