jsverse/transloco-keys-manager

Bug: this.transloco.translate('Some string') report Missing translation in browser console

Closed this issue · 1 comments

Is there an existing issue for this?

  • I have searched the existing issues

Is this a regression?

No

Current behavior

Sometimes the transloco.translate('Some token') method displays a message in the broswer console saying: missing translation for Some token, even though the string is present in the translation files, and the string is even translated on the screen.

Expected behavior

Don't display the warning: missing translate for, for strings that are in the translation files (en.json, pt.json)

Please provide a link to a minimal reproduction of the bug

I couldn't reproduce this problem in stackblitz

Transloco Config

module.exports = {
  rootTranslationsPath: 'assets/i18n/',
  langs: ['pt', 'en', 'es'],
  keysManager: {
    defaultValue: '{{key}}',
    sort: true,
    addMissingKeys: true,
    removeExtraKeys: true,
  },
};

Debug Logs

No response

Please provide the environment you discovered this bug in

Transloco: 7.0.0
Transloco Keys Manager: 4.0.1
Angular: 17.2.3
Node: 20.9.0
Package Manager: 8.9.1
OS: MacOS 13.5.2 (22G91) Ventura

Additional context

No response

I would like to make a pull request for this bug

No

@newaeonweb this isn't related to TKM.
Furthermore, please take the time to read the docs which I believe will answer your question here.

If you are still having issues feel free to open a discussion/issue in the Transloco repo.