Closed stancoffyn closed 2 years ago
@stancoffyn Thank you for your contributions! 👍
Yes, the scenario you suggested would often happen, I think. Fortunately, the current library version already allows us to support this scenario with the following "indexer" syntax.
<h1>@Products[$"product{product.Id}name"]</h1>
(See also the "Note" section in the "Step.6 - Use the Text Table" chapter in the README )
Does it make sense to you?
Perfectly, thank you. Sorry I didn't see that in the specs.
@stancoffyn No problem! Anyway, thank you for your contributions! 👍
I have a use case where I would like to use the i18n features on a product page and have specific product translations in the json document.
I am of the mind that a product with an ID of 1234 could have configurations in the translation document as follows
What I would like to be able to do is as follows:
This way products can be defined in the database, but translations could be performed outside of doing database changes. So long as the key is unchanged, compile time changes would not be required as they are loaded from the json doc.
Thoughts?