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
import Foundation | |
// Localized string struct that has single static method which accepts a `Localizeable` value. | |
struct LocalizedString { | |
// Usage: LocalizedString.localizedStringForValue(NavBarTitle.Home) | |
static func localizedStringForValue<T: Localizeable>(localizeableValue: T) -> String { | |
return NSLocalizedString(localizeableValue.localizedString, comment: localizeableValue.localizedStringComment) |