4 ms·
Obj-C and Swift allow comments to go along with translation strings, so you would add let buttonStr = NSLocalizedString("Open ticket", comment: "For user t
by seanalltogether 5y ago
Obj-C and Swift allow comments to go along with translation strings, so you would add
let buttonStr = NSLocalizedString("Open ticket", comment: "For user to open a ticket")
And the comment would make its way into the eventual xliff file sent to translators
- jraph 5y agoThis looks like the right approach: giving context to the translation strings. Many translation tools give the locations in the code where a string is used. It's a first step, though translators are not always able to read code.