Quantcast
Channel: Active questions tagged config - Stack Overflow
Viewing all articles
Browse latest Browse all 5049

Best approach for deployment specific terminology

$
0
0

I have a VueJS project that will be deployed to multiple clients. This project used to be written in PHP.

What I want is to have different versions of the strings used in the App for different clients. For example, One client would use the term 'Centre' while the other would prefer 'Branch' and so on.

Earlier in PHP, we used to have a language.php file, and an optional language.override.php with only the custom strings. The override file would be ignored from git, and manually uploaded for each client with only the overrides. Then the framework would merge these two files to build the final strings.

I'm looking for a better approach to achieve the same in Vue. I though about using Vue-i18n and having the default strings as 'en' and the overrides as some other language, so that it would fall back to the 'en' version if there is no override. But that would make it difficult to have real i18n support in the future.

Example: Lets say I have the following strings:

{    term: "term",    centre: "centre",    auditor: "auditor",}

and Client A wants 'term' to be called 'quarter', so I would have for client A:

{    term: "quarter",    centre: "centre",    auditor: "auditor",}

and say Client B wants 'centre' to be 'branch' and `auditor' to be 'fod', so I would have:

{    term: "term",    centre: "branch",    auditor: "fod",}

Do you guys have any ideas on how to best approach this?


Viewing all articles
Browse latest Browse all 5049

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>