Hi,
I use MessageService for localizing Kendo components, it works properly, but for some reason after the application starts, 'No-translation found for ...' warnings appear in the console.
combobox.component.html:3 No translation found for "7708502966028483300" ("NO DATA FOUND" - "kendo.combobox.noDataText").
combobox.component.html:3 No translation found for "2025597431468961462" ("clear" - "kendo.combobox.clearTitle").I use Nx(21.4.1) monorepo with Angular (20.1.8) and Kendo (20.0.3).
How can I solve the issue so that the warnings don't appear?
Thanks!
export const translations: () => Record<string, string> = () => ({
'kendo.textbox.clear': $localize`:@@component_textbox_clear:Törlés`,
'kendo.label.optional': $localize`:@@component_label_required:Kötelező`,
'kendo.combobox.noDataText': $localize`:@@component_combobox_noDataText:Nincs találat`,
'kendo.combobox.clearTitle': $localize`:The title of the clear button.@@component_combobox_clearTitle:Törlés`,
});import { Injectable } from'@angular/core';
import { MessageServiceasKendoMessageService } from'@progress/kendo-angular-l10n';
import { translations } from'../const/translation';
@Injectable({
providedIn: 'root',
})
exportclassMessageServiceextendsKendoMessageService {
publictranslations: Record<string, string> = translations();
publicoverrideget(key: string): string {
returnthis.translations[key] ?? key;
}
}
//app.config.ts
export const appConfig: ApplicationConfig = {
providers: [
{ provide: KendoMessageService, useClass: MessageService },
],
};