Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 19 additions & 10 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,21 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout Project
uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3
uses: actions/checkout@v4

- uses: pnpm/action-setup@v4
name: Install pnpm
with:
run_install: false

- name: Add problem matcher
run: echo "::add-matcher::.github/problemMatchers/eslint.json"
run: echo "::add-matcher::.github/problemMatchers/tsc.json"

- name: Use Node.js v20
uses: actions/setup-node@v4
with:
node-version: 20

- uses: pnpm/action-setup@v3
with:
version: 8
cache: 'pnpm'

- name: Install Dependencies
run: pnpm install --frozen-lockfile
Expand All @@ -35,16 +39,21 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout Project
uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3
uses: actions/checkout@v4

- uses: pnpm/action-setup@v4
name: Install pnpm
with:
run_install: false

- name: Add problem matcher
run: echo "::add-matcher::.github/problemMatchers/tsc.json"

- name: Use Node.js v20
uses: actions/setup-node@v4
with:
node-version: 20
- uses: pnpm/action-setup@v3
with:
version: 8
cache: 'pnpm'

- name: Install Dependencies
run: pnpm install --frozen-lockfile
Expand Down
47 changes: 47 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
import { defineConfig, globalIgnores } from 'eslint/config';
import typescriptEslint from '@typescript-eslint/eslint-plugin';
import globals from 'globals';
import tsParser from '@typescript-eslint/parser';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import js from '@eslint/js';
import { FlatCompat } from '@eslint/eslintrc';

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all,
});

export default defineConfig([
globalIgnores(['**/dist']),
{
extends: compat.extends('eslint:recommended', 'plugin:@typescript-eslint/recommended'),

plugins: {
'@typescript-eslint': typescriptEslint,
},

languageOptions: {
globals: {
...globals.browser,
},

parser: tsParser,
ecmaVersion: 5,
sourceType: 'script',

parserOptions: {
project: './tsconfig.eslint.json',
},
},

rules: {
'@typescript-eslint/switch-exhaustiveness-check': 'error',
'@typescript-eslint/consistent-type-imports': 'error',
'@typescript-eslint/no-non-null-assertion': 'off',
},
},
]);
52 changes: 32 additions & 20 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,45 +26,57 @@
"discord-transcripts"
],
"author": "Derock <derock@derock.dev>",
"license": "GNU GPLv3",
"license": "Apache-2.0",
"files": [
"dist/**/*.js",
"dist/**/*.d.ts",
"dist/**/*.js.map"
],
"devDependencies": {
"@eslint/eslintrc": "^3.3.1",
"@eslint/js": "^9.35.0",
"@types/debug": "^4.1.12",
"@types/node": "^20.11.17",
"@types/react": "^18.2.47",
"@types/react-dom": "^18.2.18",
"@typescript-eslint/eslint-plugin": "^5.62.0",
"@typescript-eslint/parser": "^5.62.0",
"debug": "^4.3.4",
"discord.js": "^14.14.1",
"dotenv": "^16.3.1",
"eslint": "^8.56.0",
"husky": "^8.0.3",
"prettier": "^2.8.8",
"pretty-quick": "^3.1.3",
"sharp": "^0.33.2",
"@types/node": "^24.3.1",
"@types/react": "^19.1.12",
"@types/react-dom": "^19.1.9",
"@typescript-eslint/eslint-plugin": "^8.43.0",
"@typescript-eslint/parser": "^8.43.0",
"debug": "^4.4.1",
"discord.js": "^14.22.1",
"dotenv": "^17.2.2",
"eslint": "^9.35.0",
"globals": "^16.4.0",
"husky": "^9.1.7",
"prettier": "^3.6.2",
"pretty-quick": "^4.2.2",
"sharp": "^0.34.3",
"ts-node": "^10.9.2",
"typescript": "^5.3.3"
"typescript": "^5.9.2"
},
"dependencies": {
"@derockdev/discord-components-core": "^3.6.1",
"@derockdev/discord-components-react": "^3.6.1",
"discord-markdown-parser": "~1.1.0",
"react": "0.0.0-experimental-6639ed3b3-20240111",
"react-dom": "0.0.0-experimental-6639ed3b3-20240111",
"discord-markdown-parser": "~1.2.0",
"react": "19.1.1",
"react-dom": "19.1.1",
"simple-markdown": "^0.7.3",
"twemoji": "^14.0.2",
"undici": "^7.9.0"
"undici": "^7.15.0"
},
"peerDependencies": {
"discord.js": "^14.0.0 || ^15.0.0"
},
"overrides": {
"react": "$react"
"react": "$react",
"react-dom": "$react-dom"
},
"pnpm": {
"peerDependencyRules": {
"allowedVersions": {
"react": "$react",
"react-dom": "$react-dom"
}
}
},
"packageManager": "pnpm@10.11.0+sha512.6540583f41cc5f628eb3d9773ecee802f4f9ef9923cc45b69890fb47991d4b092964694ec3a4f738a420c918a333062c8b925d312f42e4f0c263eb603551f977"
}
Loading