diff --git a/package.json b/package.json index f38cde8..b34b744 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@next2d/builder", - "version": "0.0.7", + "version": "0.0.8", "description": "Multi-platform builder for Next2d Framework, supporting export to various platforms such as macOS, Windows, iOS, Android and Web(HTML)", "author": "Toshiyuki Ienaga ", "license": "MIT", diff --git a/src/index.ts b/src/index.ts index 8776815..a1296f5 100644 --- a/src/index.ts +++ b/src/index.ts @@ -176,12 +176,14 @@ const loadConfig = (): Promise => ); } + const ext: string = fs.existsSync(`${process.cwd()}/vite.config.ts`) ? "ts" : "js"; + const config: any = await loadConfigFromFile( { "command": "build", "mode": "build" }, - `${process.cwd()}/vite.config.ts` + `${process.cwd()}/vite.config.${ext}` ); // update config