BTW: teach yourself like other software is doing. Example: Wordpress (the sources are public). The very huge of localization mappings is using "Canvention A". The source code contains the English default.
I think most sources have localization as an after thought and "Convention A" is the path of least resistance to go from a code base that had no original intent of being localized to one that is.
In the 90's we added localization to our 4gl application by taking any strings in the code we wanted translated and did this by adding special tokens to indicate translation should occur e.g. "Product Code" became "{ProductCode}" and a pre compilation step in our makefiles found strings of the form "{...}" to do the translation at compile time. A lot of this could be scripted. (and then when we went to Genero, scripts transformed "{ProductCode}" to %"ProductCode"
Implementing Convention B would have required more manual effort and thus been more costly in terms of time and dollars to change the existing sources.
I don't think you can say Convention A is best because you see other sources that use Convention A. You don't know what factors led to them getting there.
Convention A has its own issues in terms of how to handle near duplicates and abbreviations e.g. (ACCOUNT CODE vs Account Code vs Acct Code vs Acc Code vs Acc Cd vs A/C vs AC etc) , long blocks of text (do you give it a short token?, if so what is the cutoff length), what if text has special characters (what is delimiter, how do you delimit the delimiter), how to handle changes in text (do you change just the translation or token as well, how do you find all instances).
Personally if starting from scratch I would go down Convention B but using meaningful and structured tokens
"error.type.date.invalid.year" = "Invalid year in date"
"error.type.date.invalid.year" = "Invalid month in date"
"error.type.date.invalid.year" = "Invalid day in date"
or even better (see
https://4js.com/ask-reuben/ig-80/ for why)
"error.type.date.invalid" = "Invalid %1 in date"
but we aren't going from scratch.
Reuben