-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
24 changed files
with
5,579 additions
and
2,270 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,57 @@ | ||
name: CI/CD Pipeline | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
build_and_test: | ||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: "22" | ||
cache: "npm" | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
- name: Type check | ||
run: npm run typecheck | ||
|
||
- name: Run ESLint | ||
run: npm run lint | ||
|
||
- name: Run tests with coverage | ||
run: npm run test:ci | ||
|
||
build: | ||
needs: test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v2 | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: "18" | ||
node-version: "22" | ||
cache: "npm" | ||
|
||
- name: Install dependencies | ||
run: npm install --also=peer | ||
run: npm ci | ||
|
||
- name: Build package | ||
run: npm run build | ||
|
||
- name: Run tests | ||
run: npm run test:unit:once | ||
- name: Upload build artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: dist | ||
path: dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/prettierrc", | ||
"printWidth": 100, | ||
"singleQuote": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
import pluginVue from "eslint-plugin-vue"; | ||
import vueTsEslintConfig from "@vue/eslint-config-typescript"; | ||
import pluginVitest from "@vitest/eslint-plugin"; | ||
import skipFormatting from "@vue/eslint-config-prettier/skip-formatting"; | ||
|
||
export default [ | ||
{ | ||
name: "app/files-to-lint", | ||
files: ["**/*.{ts,mts,tsx,vue}"], | ||
}, | ||
|
||
{ | ||
name: "app/files-to-ignore", | ||
ignores: ["**/dist/**", "**/dist-ssr/**", "**/coverage/**"], | ||
}, | ||
|
||
...pluginVue.configs["flat/recommended"], | ||
...vueTsEslintConfig(), | ||
|
||
{ | ||
...pluginVitest.configs.recommended, | ||
files: ["src/**/__tests__/*"], | ||
}, | ||
skipFormatting, | ||
|
||
{ | ||
rules: { | ||
"no-console": "warn", | ||
"no-debugger": "warn", | ||
"no-var": "error", | ||
"prefer-const": "error", | ||
"no-new-object": "error", | ||
"object-shorthand": "error", | ||
"no-array-constructor": "error", | ||
"prefer-destructuring": "error", | ||
"prefer-template": "error", | ||
"func-style": "error", | ||
"no-loop-func": "error", | ||
"prefer-rest-params": "error", | ||
"default-param-last": "error", | ||
"no-param-reassign": "error", | ||
"prefer-spread": "error", | ||
"prefer-arrow-callback": "error", | ||
"no-duplicate-imports": "error", | ||
"dot-notation": "error", | ||
"no-unneeded-ternary": "error", | ||
"no-warning-comments": "warn", | ||
"no-unused-vars": "off", // Handled by "@typescript-eslint/no-unused-vars" | ||
}, | ||
}, | ||
{ | ||
rules: { | ||
"@typescript-eslint/ban-ts-comment": "warn", | ||
"@typescript-eslint/no-explicit-any": "warn", | ||
"@typescript-eslint/no-non-null-assertion": "off", | ||
"@typescript-eslint/no-unused-vars": [ | ||
"error", | ||
{ | ||
args: "all", | ||
argsIgnorePattern: "^_", | ||
caughtErrorsIgnorePattern: "^_", | ||
}, | ||
], | ||
}, | ||
}, | ||
]; |
Oops, something went wrong.