Copilot I18N

Why is Copilot using I18NProvider.translate() and not Component.getTranslation()?

There are some cases, such as inside lit renderers, here this does not refer to an instance of Component which in turn means that getTranslation() would be unavailable. That’s why we added the static variant that can be used basically anywhere without forcing the code generation to take the context into account.

1 Like

That’s what I thought. Thanks for confirming.