Skip to content

Commit cbff387

Browse files
committed
chore: add checks and tests
1 parent 078234c commit cbff387

File tree

17 files changed

+6447
-548
lines changed

17 files changed

+6447
-548
lines changed

.github/workflows/main.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@ jobs:
1616
uses: actions/checkout@v4
1717
- name: Install dependencies
1818
run: npm install
19+
- name: Lint
20+
run: npm run lint
21+
- name: Format check
22+
run: npm run format:check
23+
- name: Run tests with coverage
24+
run: npm run test:coverage
1925
- name: Build
2026
run: npx tsc
2127
- name: Merge

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
dist
22
node_modules
3+
coverage
34
ctrf

.prettierignore

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
dist/
2+
node_modules/
3+
coverage/
4+
templates/
5+
reports/
6+
community-reports/
7+
.github/
8+
.exlintrc.js
9+
README.md
10+
docs/

.prettierrc

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"semi": false,
3+
"singleQuote": true,
4+
"trailingComma": "es5",
5+
"tabWidth": 2,
6+
"useTabs": false,
7+
"printWidth": 80,
8+
"bracketSpacing": true,
9+
"arrowParens": "avoid"
10+
}

eslint.config.mjs

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
// @ts-check
2+
import js from '@eslint/js'
3+
import typescript from 'typescript-eslint'
4+
5+
export default [
6+
{
7+
ignores: [
8+
'node_modules/**',
9+
'dist/**',
10+
'coverage/**',
11+
'docs/**',
12+
'ctrf/**',
13+
'*.js',
14+
'*.mjs',
15+
'src/test-utils/**',
16+
'scripts/**',
17+
'examples/**',
18+
'final/**',
19+
'src/__tests__/**',
20+
'src/test-utils/**',
21+
'src/test-utils/**',
22+
'**/*.test.ts',
23+
'src/cli.ts',
24+
],
25+
},
26+
js.configs.recommended,
27+
...typescript.configs.recommended,
28+
{
29+
files: ['**/*.ts'],
30+
rules: {
31+
'@typescript-eslint/no-explicit-any': 'warn',
32+
'@typescript-eslint/no-unused-vars': 'error',
33+
},
34+
},
35+
]

0 commit comments

Comments
 (0)