问题
Pragma mark not working in Localizable.strings file. If I add second MARK:
(#pragma mark) in Localizable.strings, xcode rise compile time error
error: read failed: The data couldn’t be read because it isn’t in the correct format.
See below Image, When I was added the first pragma mark // MARK: MENU ITEMS
, it didn't show any error. But when I add the second mark // MARK: EMAIL SETTINGS
it shows the above error.
My intention is simple, Localizable.strings should be in organized ordered like below.
This SO post didn't clear my doubt and not get detail explanation and it's too old too. So if anyone experienced this, please give your answers/suggestion.
回答1:
Yes, it's possible.
You're missing a few required semi-colons. I guess it is used for string-termination or similar under the hood...
https://developer.apple.com/library/content/documentation/Cocoa/Conceptual/LoadingResources/Strings/Strings.html
来源:https://stackoverflow.com/questions/50062604/is-it-possible-mark-pragma-mark-in-localizable-string-file