auto-translate-json-library
Version:
Automatically translates JSON language files to other languages using Google Translate,AWS,Azure,DeepL,OpenAI or local OpenAI compatible server
14 lines (13 loc) • 488 B
TypeScript
import { type IFiles } from "./files";
import type { TranslationFile } from "./translate.interface";
export declare class FolderFiles implements IFiles {
folderPath: string;
sourceLocale: string;
targetLocales: Array<string>;
fileName: string;
constructor(filePath: string);
private getTargetLocales;
private createFileName;
loadJsonFromLocale(locale: string): Promise<TranslationFile>;
saveJsonToLocale(locale: string, file: TranslationFile): void;
}