Reputation: 3042
I have a few Text("dummy")
within SwiftUI previews. Every time I perform export localizations, these would get exported. Is there any way to manually mark them as "do not localize"?
Upvotes: 7
Views: 987
Reputation: 2215
Convenient way to use keep always safe and get rid of Text() localisation globally. It will override the default init and get rid of localisation.
extension Text {
public init<S>(_ content: S) where S : StringProtocol {
self.init(verbatim: String(content))
}
}
Upvotes: -1