text: 
  export default class LanguageService {
  	constructor() {
  		
  		//return {getMessage, addMessageBundle, getLanguage};
  	}
  	
  	getMessage(code) {
  		return i18n(code);
  	}
  	
  	getLanguage() {
  		return document.getElementsByTagName('html')[0].getAttribute('lang');
  	}
  	
  	addMessageBundle(resource, onDone) {
  		const lang = this.getLanguage();
  		if(lang && (!i18n.translator.values || i18n.translator.values.length === 0)) {
  			$.ajax('/internal/' + resource + '/messages/' + lang + '.json')
  			.done(
  					(messages) => {
  						i18n.translator.add(messages);
  						if(onDone) {
  							onDone(messages);
  						}
  					}
  			);
  		}
  	}
  }