Permalink
Browse files

fix(build): correct d.ts import for i18next

  • Loading branch information...
EisenbergEffect committed Nov 17, 2018
1 parent bcdb23b commit b43d5e050c7d86e482ce26bad2746c28ca6bf870
Showing with 3 additions and 3 deletions.
  1. +1 −1 build/build.ts
  2. +2 −2 dist/aurelia-i18n.d.ts
@@ -153,7 +153,7 @@ async function generateDts(): Promise<void> {
}
async function fixI18nDefaultImport(typeDefFileName: string) {
const importDeclaration = `import i18next from "i18next";\n`;
const importDeclaration = `import * as i18next from 'i18next';\n`;
const data = fs.readFileSync(typeDefFileName, 'utf-8');
const fd = fs.openSync(typeDefFileName, 'w+');
fs.writeSync(fd, Buffer.from(importDeclaration, 'utf8'), 0, importDeclaration.length, 0);
@@ -1,4 +1,4 @@
import i18next from "i18next";
import * as i18next from "i18next";
import { Container } from 'aurelia-dependency-injection';
import { EventAggregator } from 'aurelia-event-aggregator';
import { FrameworkConfiguration } from 'aurelia-framework';
@@ -172,4 +172,4 @@ export declare class TValueConverter {
constructor(service: I18N);
toView(value: any, options?: i18next.TranslationOptions<object>): any;
}
export declare function configure(frameworkConfig: FrameworkConfiguration, cb: (instance: I18N) => AureliaEnhancedI18Next): AureliaEnhancedI18Next;
export declare function configure(frameworkConfig: FrameworkConfiguration, cb: (instance: I18N) => AureliaEnhancedI18Next): AureliaEnhancedI18Next;

0 comments on commit b43d5e0

Please sign in to comment.