i18n support

56 views
Skip to first unread message

Mark Lester

unread,
Sep 26, 2020, 9:17:30 PM9/26/20
to Derby
I have been playing with LiquidJS and have implemented DB version of gettext with a view to making i18n as cheap as possible for arbitrary locales. For this we need some instance of a global translation hub, I have been investigating pontoon.mozilla.org, but we also need automatic resolution of translation markup for any new locale. I am fairly python ignorant, pontoon is almost totally python which led me to Django. Curiously, my markup of {%translate "a phrase" [context "a slug"] %} is identical to Django's template syntax. But as it stands it's still using gettext and .po files. I can live with.po files as a transmission standard, it is what it is. Loading all translations for all possible locales is not ideal though I guess in this day and age feasible. My gripe is more that I want to automatically insert newly encountered phrases upon the executing/evaluation of assets. That is, you dont need to do anything more than execute a fetch on all your files in order to populate your translation system. You can then periodically, or perhaps even by a subscription model, fetch translations from a globally maintained translation database, and/or provide your own via a local deployment of pontoon or other solution, and have that uploaded and shared with the global community.
Can I use, that is has there been anything implemented,  for LiquidJS within Derby ? I noted your sever/client side pluralism, but we also need "once" and "every time" execution. For this I had proposed three levels of markup so that you could resolve translations (and potentially stuff like server side inclusions that are constant) , but also combine server and client side execution in the same template. I accept that you wouldnt normally want to do both in the same file, but there are some instances and it means you are explicitly marking up where you want the execution to occur. I presume I have to otherwise tell Derby where we want the template execution to occur.
Is there any specific i18n work within Derby that I can look at.

Christina Burger

unread,
Nov 12, 2020, 9:38:37 AM11/12/20
to Derby
Hi there! This group is being archived. Please post any new issues to our Github: https://github.com/derbyjs/derby/issues

To answer your question, there is no existing i18n support for Derby at this moment. 
Reply all
Reply to author
Forward
0 new messages