Skip to content

Commit eb6853e

Browse files
chore: update dependencies & switch to vitest
1 parent 40b1be3 commit eb6853e

38 files changed

+7909
-5022
lines changed

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/dist

.eslintrc.json

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"root": true,
3+
"parser": "@typescript-eslint/parser",
4+
"parserOptions": {
5+
"ecmaVersion": 2022,
6+
"sourceType": "module"
7+
},
8+
"ignorePatterns": ["node_modules", "build", "coverage"],
9+
"env": {
10+
"es6": true,
11+
"node": true
12+
},
13+
"extends": [
14+
"prettier",
15+
"eslint:recommended",
16+
"plugin:@typescript-eslint/recommended"
17+
],
18+
"plugins": ["@typescript-eslint", "prettier"],
19+
"rules": {
20+
"no-var": "error",
21+
"no-multi-spaces": "error",
22+
"space-in-parens": "error",
23+
"no-multiple-empty-lines": "error",
24+
"no-constant-condition": ["error", { "checkLoops": false }],
25+
"prefer-const": "error",
26+
"max-lines-per-function": ["warn", 80],
27+
"no-shadow": "off",
28+
"@typescript-eslint/no-shadow": "error",
29+
"@typescript-eslint/no-unsafe-declaration-merging": "off",
30+
"@typescript-eslint/no-unused-vars": "off",
31+
"prettier/prettier": [
32+
"warn",
33+
{
34+
"printWidth": 80,
35+
"singleQuote": true,
36+
"endOfLine": "auto"
37+
}
38+
]
39+
}
40+
}
Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
1-
name: TypeScript Compile and Test CI
1+
name: Test
22

33
on:
44
push:
5-
branches: [master]
5+
branches: [ main ]
66

77
jobs:
88
build:
99
runs-on: ubuntu-latest
1010

1111
strategy:
1212
matrix:
13-
node-version: [14.x]
13+
node-version: [20.x]
1414

1515
steps:
1616
- name: Checkout
17-
uses: actions/checkout@v2
17+
uses: actions/checkout@v3
1818

1919
- name: Use Node.js ${{ matrix.node-version }}
20-
uses: actions/setup-node@v1
20+
uses: actions/setup-node@v3
2121
with:
2222
node-version: ${{ matrix.node-version }}
2323

2424
- name: Cache node_modules directory
25-
uses: actions/cache@v2
25+
uses: actions/cache@v3
2626
with:
2727
path: '**/node_modules'
2828
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
@@ -34,4 +34,4 @@ jobs:
3434
run: yarn build-ts
3535

3636
- name: Run Tests
37-
run: yarn test
37+
run: yarn test:ci

.gitignore

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,13 @@
1-
dist/
2-
node_modules/
1+
# yarn cache
2+
.yarn/*
3+
.yarn/cache
4+
!.yarn/patches
5+
!.yarn/releases
6+
!.yarn/plugins
7+
!.yarn/sdks
8+
!.yarn/versions
9+
10+
11+
coverage/
12+
node_modules/
13+
dist/

.husky/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
_

.husky/commit-msg

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/sh
2+
. "$(dirname "$0")/_/husky.sh"
3+
. "$(dirname "$0")/common.sh"
4+
5+
yarn commitlint --edit $1

.husky/common.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
command_exists () {
2+
command -v "$1" >/dev/null 2>&1
3+
}
4+
5+
# Workaround for Windows 10, Git Bash and Yarn
6+
if command_exists winpty && test -t 1; then
7+
exec < /dev/tty
8+
fi

.husky/pre-commit

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/sh
2+
. "$(dirname "$0")/_/husky.sh"
3+
. "$(dirname "$0")/common.sh"
4+
5+
yarn lint-staged

.husky/pre-push

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/sh
2+
. "$(dirname "$0")/_/husky.sh"
3+
4+
yarn test:ci

.husky/prepare-commit-msg

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/sh
2+
. "$(dirname "$0")/_/husky.sh"
3+
. "$(dirname "$0")/common.sh"
4+
5+
exec < /dev/tty && yarn cz --hook || true

0 commit comments

Comments
 (0)