Would it be feasible to add support for general place-holders, where one localised string could refer to another one? This would enable common terms/phrases to be used in the content of others, without requiring parameter parsing at the code level.
For example;
{
"contact service desk": "contact Service Desk (x3000)",
"wrong id": "You've entered a wrong ID. Please try again, or {{contact service desk}} for further assistance",
"db error": "Oops! Something is wrong with our servers. If this problem persists, please {{contact service desk}}"
}
In this way, any mention of contacting the Service Desk is consistent, and if the message (eg; the phone extension) changes, it's reflected across all other references.
Preferably, such a feature would be able to be enabled/disabled, and the place-holder syntax be customisable, to avoid clashes with real content syntax in templates, etc...
Here's an idea for an alternative syntax:
{
"contact service desk": "contact Service Desk (x3000)",
"wrong id": ["You've entered a wrong ID. Please try again, or %p for further assistance", "contact service desk"],
"db error": ["Oops! Something is wrong with our servers. If this problem persists, please %p", "contact service desk"]
}
This syntax is similar to the "%s" place-holder syntax, but in this case, the substituted value is another i18n entry, named within the locales config.