KendoUI Bridge Documentation
  • Introduction
  • About this application
    • Introduction
    • Navigation guide
    • Components catalog
    • Installation
    • Catalog index
    • Themes selector
  • About Aurelia
    • Key features
  • About KendoUI
    • Integrated with Aurelia
    • Why choose KendoUI
  • Developers tutorials
    • Introduction
    • Sample application structure
    • esnext - kendo
    • esnext-aspnetcore - kendo-2017
    • esnext-aspnetcore - kendo-2015
    • typescript - kendo
    • typescript-aspnetcore - kendo
    • esnext- webpack
    • typescript-webpack kendo
  • Developers notes
    • Current limitations
    • Loading a subset of controls
    • Lazy loading wrappers
    • Running gists
    • Kendo Tooltip HTML content
    • Bundling details
    • Dynamic content creation
    • Bundling step by step instructions
    • What you need to know
    • Localization
    • Prevent JSPM from loading jQuery
  • Bridge developers notes
    • Introduction
    • Bridge utilities
    • Generation of bindables
    • Babel DTS generator
    • Grid HTML api
    • Template compilation
    • Harvesting bindable variables
    • Registry helper class
    • Creating gists for the catalog app
  • Troubleshooting
    • Introduction
    • Using gists and GistRun
Powered by GitBook
On this page
  • 5.10 Localization
  • JSPM
  • Aurelia-CLI
  1. Developers notes

Localization

Application Developer notes

5.10 Localization

JSPM

In order to load a Kendo translation file, the following import statements can be added to main.js:

import 'kendo.core.min';
import 'kendo-ui/js/messages/kendo.messages.nl-NL.min';
import 'kendo-ui/js/cultures/kendo.culture.nl-NL.min';

kendo.core.min is imported to ensure that the kendo global is available for the localization files to attach to.

This by itself has no effect and Kendo will still use the default en-US localization. In main.js you also have to call kendo.culture('nl-NL'); for Kendo to switch the localization to nl-NL.

Aurelia-CLI

Example configuration for aurelia-cli:

import 'kendo-ui-core/js/kendo.core';
import 'kendo-ui-core/js/cultures/kendo.culture.nl-NL';
import environment from './environment';

//Configure Bluebird Promises.
Promise.config({
  longStackTraces: environment.debug,
  warnings: {
    wForgottenReturn: false
  }
});

export function configure(aurelia) {
  aurelia.use
    .standardConfiguration()
    .feature('resources');

  if (environment.debug) {
    aurelia.use.developmentLogging();
  }

  if (environment.testing) {
    aurelia.use.plugin('aurelia-testing');
  }

  kendo.culture('nl-NL');

  aurelia.start().then(() => aurelia.setRoot());
}

Note that kendo.core gets loaded first (so that the kendo global is registered), and kendo.culture.nl-NL is loaded afterwards. This by itself has no effect, until you tell kendo that the default culture should be nl-NL as well. This is done with the line kendo.culture('nl-NL');

PreviousWhat you need to knowNextPrevent JSPM from loading jQuery

Last updated 7 years ago