Defining `defaultVariables` value in Tolgee config
interpolation: {
defaultVariables: {
brandName: 'test',
},
},
I did not find this option using solely Tolgee, it is available in i18next and helps to have minimal translations without the need to define some variables every time.
I don't like this approach very much, it makes things easier, but also can feel more like magic, because it makes it harder to see where is the parameter coming from. Also, you can do this easily by creating your custom T component or t function where you pass this manually.
What do you think @JanCizmar
The only issue I see in creating the custom T or t is that the extractor wouldn't understand these. Apart from this I agree.
I'd be for making the extractor more relaxed, e.g. not to check where is the <T> component coming from.
This hasn't been implemented, right? Issue was closed as completed, but I can't find anywhere how to do this.
Hello, you are right. I can reopen this, but I'm still not sure if it's a good approach. Global settings are powerful, however make it harder for code readability.