chore: add code quality tooling
This commit is contained in:
15
biome.json
Normal file
15
biome.json
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
{
|
||||||
|
"formatter": {
|
||||||
|
"enabled": true,
|
||||||
|
"indentStyle": "space",
|
||||||
|
"indentWidth": 2,
|
||||||
|
"includes": ["src/**/*.ts", "tests/**/*.ts", "*.json", "*.ts"]
|
||||||
|
},
|
||||||
|
"linter": {
|
||||||
|
"enabled": true,
|
||||||
|
"rules": {
|
||||||
|
"recommended": true
|
||||||
|
},
|
||||||
|
"includes": ["src/**/*.ts", "tests/**/*.ts", "*.json", "*.ts"]
|
||||||
|
}
|
||||||
|
}
|
||||||
10
package.json
10
package.json
@@ -5,7 +5,11 @@
|
|||||||
"main": "src/index.ts",
|
"main": "src/index.ts",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "bun --watch src/index.ts",
|
"dev": "bun --watch src/index.ts",
|
||||||
"start": "bun src/index.ts"
|
"start": "bun src/index.ts",
|
||||||
|
"typecheck": "tsc --noEmit",
|
||||||
|
"lint": "biome check .",
|
||||||
|
"format": "biome format --write .",
|
||||||
|
"test": "vitest run"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@discordjs/opus": "^0.10.0",
|
"@discordjs/opus": "^0.10.0",
|
||||||
@@ -24,9 +28,11 @@
|
|||||||
"ws": "^8.20.1"
|
"ws": "^8.20.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@biomejs/biome": "latest",
|
||||||
"@types/bun": "latest",
|
"@types/bun": "latest",
|
||||||
"@types/express": "^5.0.6",
|
"@types/express": "^5.0.6",
|
||||||
"@types/fluent-ffmpeg": "^2.1.28",
|
"@types/fluent-ffmpeg": "^2.1.28",
|
||||||
"@types/ws": "^8.18.1"
|
"@types/ws": "^8.18.1",
|
||||||
|
"vitest": "latest"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
8
vitest.config.ts
Normal file
8
vitest.config.ts
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
import { defineConfig } from 'vitest/config';
|
||||||
|
|
||||||
|
export default defineConfig({
|
||||||
|
test: {
|
||||||
|
environment: 'node',
|
||||||
|
include: ['tests/**/*.test.ts']
|
||||||
|
}
|
||||||
|
});
|
||||||
Reference in New Issue
Block a user