1 | (function (global, factory) {
|
2 | typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
|
3 | typeof define === 'function' && define.amd ? define('@ngx-translate/http-loader', ['exports'], factory) :
|
4 | (global = global || self, factory((global['ngx-translate'] = global['ngx-translate'] || {}, global['ngx-translate']['http-loader'] = {})));
|
5 | }(this, (function (exports) { 'use strict';
|
6 |
|
7 | var TranslateHttpLoader = (function () {
|
8 | function TranslateHttpLoader(http, prefix, suffix) {
|
9 | if (prefix === void 0) { prefix = "/assets/i18n/"; }
|
10 | if (suffix === void 0) { suffix = ".json"; }
|
11 | this.http = http;
|
12 | this.prefix = prefix;
|
13 | this.suffix = suffix;
|
14 | }
|
15 | |
16 |
|
17 |
|
18 | TranslateHttpLoader.prototype.getTranslation = function (lang) {
|
19 | return this.http.get("" + this.prefix + lang + this.suffix);
|
20 | };
|
21 | return TranslateHttpLoader;
|
22 | }());
|
23 |
|
24 | |
25 |
|
26 |
|
27 |
|
28 | exports.TranslateHttpLoader = TranslateHttpLoader;
|
29 |
|
30 | Object.defineProperty(exports, '__esModule', { value: true });
|
31 |
|
32 | })));
|
33 |
|