- Copy eslint configs from TransPlace's moderation bot
- Modify some settings to better fit this project
pull/6/head
Skyler Grey 3 years ago
parent 9106564cf8
commit aa50824027
Signed by: Minion3665
GPG Key ID: 1AFD10256B3C714D

@ -0,0 +1,48 @@
{
"env": {
"browser": false,
"es2021": true
},
"ignorePatterns": ["dist/"],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module"
},
"plugins": [
"@typescript-eslint"
],
"rules": {
"indent": [
"error",
4
],
"linebreak-style": [
"error",
"unix"
],
"quotes": [
"error",
"double"
],
"semi": [
"error",
"always"
],
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": [
"warn",
{
"argsIgnorePattern": "^_",
"varsIgnorePattern": "^_",
"caughtErrorsIgnorePattern": "^_"
}
],
"no-trailing-spaces": "error",
"@typescript-eslint/no-explicit-any": "error"
}
}

@ -5,6 +5,7 @@
"agenda": "^4.3.0", "agenda": "^4.3.0",
"body-parser": "^1.20.0", "body-parser": "^1.20.0",
"discord.js": "13.8.1", "discord.js": "13.8.1",
"eslint": "^8.21.0",
"express": "^4.18.1", "express": "^4.18.1",
"fuse.js": "^6.6.2", "fuse.js": "^6.6.2",
"humanize-duration": "^3.27.1", "humanize-duration": "^3.27.1",
@ -24,7 +25,8 @@
"scripts": { "scripts": {
"build": "tsc", "build": "tsc",
"start": "node --experimental-json-modules dist/index.js", "start": "node --experimental-json-modules dist/index.js",
"dev": "rm -rf dist && tsc && node --experimental-json-modules dist/index.js" "dev": "rm -rf dist && tsc && node --experimental-json-modules dist/index.js",
"lint": "eslint ."
}, },
"repository": { "repository": {
"type": "git", "type": "git",
@ -41,5 +43,10 @@
}, },
"homepage": "https://github.com/ClicksMinutePer/Nucleus#readme", "homepage": "https://github.com/ClicksMinutePer/Nucleus#readme",
"private": false, "private": false,
"type": "module" "type": "module",
"devDependencies": {
"@tsconfig/node16-strictest-esm": "^1.0.3",
"@typescript-eslint/eslint-plugin": "^5.32.0",
"@typescript-eslint/parser": "^5.32.0"
}
} }

@ -1,4 +1,5 @@
{ {
"extends": "@tsconfig/node16-strictest-esm/tsconfig.json",
"compilerOptions": { "compilerOptions": {
"module": "esnext", "module": "esnext",
"target": "es2020", "target": "es2020",
@ -13,4 +14,4 @@
}, },
"include": ["src/**/*", "installer.js"], "include": ["src/**/*", "installer.js"],
"exclude": [] "exclude": []
} }

Loading…
Cancel
Save