From 47dfe5513c3780076c77f020089a3b2fe9b60a15 Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 12:16:15 +0900 Subject: [PATCH 1/8] update README.md --- template/README.md | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/template/README.md b/template/README.md index 5721f1a..7a8ab0b 100644 --- a/template/README.md +++ b/template/README.md @@ -9,27 +9,35 @@ In the project directory, you can run: ### `npm start` Runs the app in the development mode. -Open [http://localhost:8080](http://localhost:8080) to view it in your browser. - +Open [http://localhost:5173](http://localhost:5173) to view it in your browser. The page will reload when you make changes. -You may also see any lint errors in the console. -### `npm run ios -- --env prd` -### `npm run android -- --env prd` -### `npm run windows -- --env prd` -### `npm run macos -- --env prd` +## Start the emulator for each platform. + +### `npm run preview:windows -- --env prd` +### `npm run preview:macos -- --env prd` +### `npm run preview:linux -- --env prd` +### `npm run preview:ios -- --env prd` +### `npm run preview:android -- --env prd` -Start the emulator for each platform. +Launch emulators for various platforms including Windows, macOS, Linux, iOS, Android, and Web (HTML). +You can check the operation of the application in the environment specified by env=***. ### `npm run generate` Generate the necessary View and ViewModel classes from the routing JSON file. +## Unit Test + ### `npm test` Launches the test runner. -### `npm run build -- --platform web --env prd` +### `npm run build:web` +### `npm run build:steam:windows` +### `npm run build:steam:macos` +### `npm run build:steam:linux` +### `npm run build -- --platform *** --env***` Multi-platform builder, writes to various platforms including macOS, Windows, iOS, Android, and Web (HTML). Builds apps for the environment specified by env=***. From 0b1a4c30145d4104733eb57f7a3d030be175a6be Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 13:57:01 +0900 Subject: [PATCH 2/8] =?UTF-8?q?#16=20=E8=A8=AD=E5=AE=9A=E3=83=95=E3=82=A1?= =?UTF-8?q?=E3=82=A4=E3=83=AB=E3=82=92=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/publish.yml | 1 - template/.gitignore | 3 +-- template/package.json | 4 +--- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 4760da1..9f95f3f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -12,7 +12,6 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: - node-version: "18.x" registry-url: "https://registry.npmjs.org" - run: npm publish --access public env: diff --git a/template/.gitignore b/template/.gitignore index 850723b..fb28a55 100644 --- a/template/.gitignore +++ b/template/.gitignore @@ -25,5 +25,4 @@ dist-ssr src/Packages.ts src/config/Config.ts -electron.index.json -out/ \ No newline at end of file +electron.index.json \ No newline at end of file diff --git a/template/package.json b/template/package.json index 27a343e..28822ba 100644 --- a/template/package.json +++ b/template/package.json @@ -18,9 +18,7 @@ "build": "npx @next2d/builder", "lint": "eslint src/**/*.ts", "test": "npx vitest", - "generate": "npx @next2d/view-generator", - "package": "electron-forge package", - "make": "electron-forge make" + "generate": "npx @next2d/view-generator" }, "devDependencies": { "@capacitor/android": "^5.5.1", From 7e71e09713e5c1a5a8581b914a2d9636f6e931d5 Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 16:53:12 +0900 Subject: [PATCH 3/8] =?UTF-8?q?#16=20=E8=A8=AD=E5=AE=9A=E3=83=95=E3=82=A1?= =?UTF-8?q?=E3=82=A4=E3=83=AB=E3=82=92=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/lint.yml | 28 +++++++++++++++++++ .github/workflows/lint.yml | 28 +++++++++++++++++++ package.json | 2 +- template/.eslintrc.json | 5 +++- template/.gitignore | 4 +-- template/package.json | 2 -- .../event/home/HomeButtonMouseDownEvent.ts | 2 +- 7 files changed, 64 insertions(+), 7 deletions(-) create mode 100644 .github/lint.yml create mode 100644 .github/workflows/lint.yml diff --git a/.github/lint.yml b/.github/lint.yml new file mode 100644 index 0000000..6740176 --- /dev/null +++ b/.github/lint.yml @@ -0,0 +1,28 @@ +name: Lint + +on: + push: + branches: + - main + - develop + pull_request: + branches: + - main + - develop + +jobs: + macos-browser-test: + runs-on: macos-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + - run: npm install + - run: npm run lint + + windows-browser-test: + runs-on: windows-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + - run: npm install + - run: npm run lint \ No newline at end of file diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 0000000..cb0137c --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,28 @@ +name: Lint + +on: + push: + branches: + - main + - develop + pull_request: + branches: + - main + - develop + +jobs: + macos-browser-test: + runs-on: macos-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + - run: npm install + - run: npx eslint ./template/src/**/*.ts + + windows-browser-test: + runs-on: windows-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + - run: npm install + - run: npx eslint ./template/src/**/*.ts \ No newline at end of file diff --git a/package.json b/package.json index 96e8da0..939eda1 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@next2d/framework-typescript-template", "description": "Next2D Framework default TypeScript template.", - "version": "2.0.0", + "version": "2.0.1", "homepage": "https://next2d.app", "bugs": "https://github.com/Next2D/framework-typescript-template/issues/new", "author": "Toshiyuki Ienaga", diff --git a/template/.eslintrc.json b/template/.eslintrc.json index 97ac4d0..d52e1e5 100644 --- a/template/.eslintrc.json +++ b/template/.eslintrc.json @@ -7,7 +7,10 @@ "sourceType": "module", "ecmaVersion": "latest" }, - "extends": "plugin:@typescript-eslint/eslint-recommended", + "extends": [ + "eslint:recommended", + "plugin:@typescript-eslint/eslint-recommended" + ], "parser": "@typescript-eslint/parser", "rules": { "no-var": "error", diff --git a/template/.gitignore b/template/.gitignore index fb28a55..a4ada40 100644 --- a/template/.gitignore +++ b/template/.gitignore @@ -23,6 +23,6 @@ dist-ssr *.sln *.sw? -src/Packages.ts -src/config/Config.ts +src/Packages.* +src/config/Config.* electron.index.json \ No newline at end of file diff --git a/template/package.json b/template/package.json index 28822ba..e960875 100644 --- a/template/package.json +++ b/template/package.json @@ -2,7 +2,6 @@ "name": "@next2d/framework-typescript-template", "version": "0.0.1", "description": "Next2D Framework TypeScript template.", - "main": "src/index.ts", "type": "module", "scripts": { "start": "vite", @@ -16,7 +15,6 @@ "build:steam:linux": "npx @next2d/builder --platform steam:linux --env prd", "build:web": "npx @next2d/builder --platform web --env prd", "build": "npx @next2d/builder", - "lint": "eslint src/**/*.ts", "test": "npx vitest", "generate": "npx @next2d/view-generator" }, diff --git a/template/src/model/domain/event/home/HomeButtonMouseDownEvent.ts b/template/src/model/domain/event/home/HomeButtonMouseDownEvent.ts index 40828ad..54d6f58 100644 --- a/template/src/model/domain/event/home/HomeButtonMouseDownEvent.ts +++ b/template/src/model/domain/event/home/HomeButtonMouseDownEvent.ts @@ -5,7 +5,7 @@ import type { Sprite } from "@next2d/display"; /** * @description Home画面のキャラクターの移動開始処理 * Processes the start of character movement on the Home screen. - * + * * @return {void} * @method * @public From a302ed69ef80a723c9cf51e3ac10f9a0b724dd10 Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 17:28:14 +0900 Subject: [PATCH 4/8] =?UTF-8?q?#16=20Lint=E3=82=92=E5=B0=8E=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/lint.yml | 28 ---------------------------- .github/workflows/lint.yml | 2 ++ 2 files changed, 2 insertions(+), 28 deletions(-) delete mode 100644 .github/lint.yml diff --git a/.github/lint.yml b/.github/lint.yml deleted file mode 100644 index 6740176..0000000 --- a/.github/lint.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: Lint - -on: - push: - branches: - - main - - develop - pull_request: - branches: - - main - - develop - -jobs: - macos-browser-test: - runs-on: macos-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - - run: npm install - - run: npm run lint - - windows-browser-test: - runs-on: windows-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - - run: npm install - - run: npm run lint \ No newline at end of file diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index cb0137c..52c1c10 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -17,6 +17,7 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 - run: npm install + - run: ls -al - run: npx eslint ./template/src/**/*.ts windows-browser-test: @@ -25,4 +26,5 @@ jobs: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 - run: npm install + - run: ls -al - run: npx eslint ./template/src/**/*.ts \ No newline at end of file From 17a1babffb76e8bef6cf1771e7da384fb48c5550 Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 17:30:57 +0900 Subject: [PATCH 5/8] =?UTF-8?q?#16=20Lint=E3=82=92=E5=B0=8E=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/lint.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 52c1c10..26f7aff 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -16,15 +16,15 @@ jobs: steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 + - run: cd template - run: npm install - - run: ls -al - - run: npx eslint ./template/src/**/*.ts + - run: npx eslint ./src/**/*.ts windows-browser-test: runs-on: windows-latest steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 + - run: cd template - run: npm install - - run: ls -al - - run: npx eslint ./template/src/**/*.ts \ No newline at end of file + - run: npx eslint ./src/**/*.ts \ No newline at end of file From 5b0237b3bf71b35c6e8daa69f373310c4ec34f1e Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 17:34:46 +0900 Subject: [PATCH 6/8] =?UTF-8?q?#16=20Lint=E3=82=92=E5=B0=8E=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/lint.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 26f7aff..be5629a 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -18,6 +18,7 @@ jobs: - uses: actions/setup-node@v3 - run: cd template - run: npm install + - run: ls -al - run: npx eslint ./src/**/*.ts windows-browser-test: @@ -27,4 +28,5 @@ jobs: - uses: actions/setup-node@v3 - run: cd template - run: npm install + - run: ls -al - run: npx eslint ./src/**/*.ts \ No newline at end of file From 36b476fc875bac9c591174a2a66999e744c6ef2e Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 17:37:08 +0900 Subject: [PATCH 7/8] =?UTF-8?q?#16=20Lint=E3=82=92=E5=B0=8E=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/lint.yml | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index be5629a..6e70c6d 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -16,17 +16,11 @@ jobs: steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 - - run: cd template - - run: npm install - - run: ls -al - - run: npx eslint ./src/**/*.ts + - run: cd template && npm install && ls -al && npx eslint ./src/**/*.ts windows-browser-test: runs-on: windows-latest steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 - - run: cd template - - run: npm install - - run: ls -al - - run: npx eslint ./src/**/*.ts \ No newline at end of file + - run: cd template && npm install && ls -al && npx eslint ./src/**/*.ts \ No newline at end of file From 4d07367dfb9f9ac403bcf3bb961e3b69a45f7438 Mon Sep 17 00:00:00 2001 From: ienaga Date: Sat, 11 Nov 2023 17:39:54 +0900 Subject: [PATCH 8/8] =?UTF-8?q?#16=20Lint=E3=82=92=E5=B0=8E=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/lint.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 6e70c6d..71301b6 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -16,11 +16,11 @@ jobs: steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 - - run: cd template && npm install && ls -al && npx eslint ./src/**/*.ts + - run: cd template && npm install && npx eslint ./src/**/*.ts windows-browser-test: runs-on: windows-latest steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 - - run: cd template && npm install && ls -al && npx eslint ./src/**/*.ts \ No newline at end of file + - run: cd template && npm install && npx eslint ./src/**/*.ts \ No newline at end of file