mirror of
https://github.com/an-anime-team/an-anime-game-launcher.git
synced 2025-03-08 09:07:57 +03:00
make i18n importable instead of needing require
This commit is contained in:
parent
dd56953225
commit
7ccd6d7d5a
4 changed files with 4 additions and 4 deletions
|
@ -1,5 +1,5 @@
|
|||
import $ from 'cash-dom';
|
||||
const i18n = new(require('./i18n'));
|
||||
import i18n from './i18n';
|
||||
|
||||
type LauncherState =
|
||||
'patch-unavailable' |
|
||||
|
|
|
@ -21,4 +21,4 @@ i18n.prototype.translate = function(phrase: any) {
|
|||
return translation
|
||||
}
|
||||
|
||||
module.exports = i18n;
|
||||
export default new (i18n as any);
|
|
@ -2,9 +2,9 @@ const path = require('path');
|
|||
const fs = require('fs');
|
||||
const { exec } = require('child_process');
|
||||
const { ipcRenderer } = require('electron');
|
||||
const i18n = new(require('./i18n'));
|
||||
|
||||
import $ from 'cash-dom';
|
||||
import i18n from './i18n';
|
||||
|
||||
import { Genshinlib } from './Genshinlib';
|
||||
import { LauncherUI } from './LauncherUI';
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
const i18n = new(require('./i18n'));
|
||||
|
||||
import $ from 'cash-dom';
|
||||
import i18n from './i18n';
|
||||
import { Genshinlib } from './Genshinlib';
|
||||
|
||||
$(() => {
|
||||
|
|
Loading…
Add table
Reference in a new issue