有没有更好的方法来获得本地化格式并用 Xcode 8 Swift 3 替换字符串?我是否需要使用 NSString,并在 NSString 和 String 之间来回转换?
let localizedDue = NSString.localizedStringWithFormat(NSLocalizedString("Due: %@", comment: "due date label with date") as NSString, formattedDate) as String
有没有更好的方法来获得本地化格式并用 Xcode 8 Swift 3 替换字符串?我是否需要使用 NSString,并在 NSString 和 String 之间来回转换?
let localizedDue = NSString.localizedStringWithFormat(NSLocalizedString("Due: %@", comment: "due date label with date") as NSString, formattedDate) as String