-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
2,303 additions
and
4,814 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"eslint.experimental.useFlatConfig": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,5 +18,6 @@ | |
"husky": "^9.0.11", | ||
"is-ci": "^3.0.1", | ||
"release-it": "^16.3.0" | ||
} | ||
}, | ||
"packageManager": "[email protected]+sha512.98a80fd11c2e7096747762304106432b3ddc67dcf54b5a8c01c93f68a2cd5e05e6821849522a06fb76284d41a2660d5e334f2ee3bbf29183bf2e739b1dafa771" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
108 changes: 108 additions & 0 deletions
108
packages/eslint-config-tslint-base/lib/tslint-config.mjs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
import path from 'node:path'; | ||
import { fileURLToPath } from 'node:url'; | ||
import { fixupPluginRules } from '@eslint/compat'; | ||
import { FlatCompat } from '@eslint/eslintrc'; | ||
import js from '@eslint/js'; | ||
import typescriptEslint from '@typescript-eslint/eslint-plugin'; | ||
import tsParser from '@typescript-eslint/parser'; | ||
import _import from 'eslint-plugin-import'; | ||
import jsonFiles from 'eslint-plugin-json-files'; | ||
import sortKeysFix from 'eslint-plugin-sort-keys-fix'; | ||
import globals from 'globals'; | ||
|
||
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 [ | ||
{ | ||
ignores: ['**/.eslintrc.js'], | ||
}, | ||
...compat.extends('eslint:recommended', 'plugin:eslint-comments/recommended'), | ||
{ | ||
plugins: { | ||
'@typescript-eslint': typescriptEslint, | ||
'sort-keys-fix': sortKeysFix, | ||
import: fixupPluginRules(_import), | ||
}, | ||
|
||
languageOptions: { | ||
globals: { | ||
...globals.node, | ||
}, | ||
|
||
parser: tsParser, | ||
ecmaVersion: 2020, | ||
sourceType: 'module', | ||
|
||
parserOptions: { | ||
project: ['./tsconfig.json'], | ||
}, | ||
}, | ||
}, | ||
...compat | ||
.extends( | ||
'eslint:recommended', | ||
'plugin:@typescript-eslint/eslint-recommended', | ||
'plugin:@typescript-eslint/recommended', | ||
'plugin:@typescript-eslint/recommended-requiring-type-checking', | ||
) | ||
.map((config) => ({ | ||
...config, | ||
files: ['**/*.ts'], | ||
})), | ||
{ | ||
files: ['**/*.ts'], | ||
rules: { | ||
'@typescript-eslint/ban-ts-comment': 'off', | ||
'@typescript-eslint/ban-types': 'off', | ||
'@typescript-eslint/consistent-type-imports': 'error', | ||
'@typescript-eslint/explicit-module-boundary-types': 'off', | ||
'@typescript-eslint/indent': 'off', | ||
'@typescript-eslint/no-empty-function': 'off', | ||
'@typescript-eslint/no-empty-interface': 'off', | ||
'@typescript-eslint/no-explicit-any': 'off', | ||
'@typescript-eslint/no-misused-promises': 'off', | ||
'@typescript-eslint/no-non-null-assertion': 'off', | ||
'@typescript-eslint/no-unnecessary-type-assertion': 'off', | ||
'@typescript-eslint/no-unsafe-argument': 'warn', | ||
'@typescript-eslint/no-unsafe-assignment': 'off', | ||
'@typescript-eslint/no-unsafe-call': 'off', | ||
'@typescript-eslint/no-unsafe-member-access': 'off', | ||
'@typescript-eslint/no-unsafe-return': 'off', | ||
'@typescript-eslint/no-use-before-define': 'off', | ||
'@typescript-eslint/no-var-requires': 'off', | ||
'@typescript-eslint/restrict-plus-operands': 'off', | ||
'@typescript-eslint/restrict-template-expressions': 'off', | ||
'eslint-comments/disable-enable-pair': 'error', | ||
'eslint-comments/no-aggregating-enable': 'error', | ||
'eslint-comments/no-duplicate-disable': 'error', | ||
'eslint-comments/no-unlimited-disable': 'error', | ||
'eslint-comments/no-unused-disable': 'error', | ||
'eslint-comments/no-unused-enable': 'error', | ||
'import/first': 'error', | ||
'import/newline-after-import': 'error', | ||
'import/no-duplicates': 'error', | ||
'no-empty': 'off', | ||
'no-useless-escape': 'off', | ||
'sort-keys-fix/sort-keys-fix': 'warn', | ||
}, | ||
}, | ||
{ | ||
files: ['**/*.json'], | ||
plugins: { | ||
'json-files': jsonFiles, | ||
}, | ||
rules: { | ||
'json-files/require-engines': 'warn', | ||
'json-files/require-license': 'warn', | ||
'json-files/require-unique-dependency-names': 'error', | ||
'json-files/sort-package-json': 'warn', | ||
}, | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,26 @@ | ||
{ | ||
"name": "@chieforz/eslint-config-tslint-base", | ||
"version": "1.2.6", | ||
"keywords": [ | ||
"tslint", | ||
"tslint-config", | ||
"tslint config" | ||
], | ||
"keywords": ["tslint", "tslint-config", "tslint config"], | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/ChiefORZ/tslint-config" | ||
}, | ||
"license": "MIT", | ||
"author": "ChiefORZ <[email protected]>", | ||
"main": "lib/tslint-config.js", | ||
"type": "module", | ||
"exports": { | ||
".": "./lib/tslint-config.mjs" | ||
}, | ||
"main": "lib/tslint-config.mjs", | ||
"directories": { | ||
"lib": "lib" | ||
}, | ||
"files": [ | ||
"lib" | ||
], | ||
"files": ["lib"], | ||
"dependencies": { | ||
"@eslint/compat": "^1.0.3", | ||
"@eslint/eslintrc": "^3.1.0", | ||
"@eslint/js": "^9.4.0", | ||
"@typescript-eslint/eslint-plugin": "^7.7.1", | ||
"@typescript-eslint/eslint-plugin-tslint": "^7.0.2", | ||
"@typescript-eslint/parser": "^7.7.1", | ||
|
@@ -29,10 +30,11 @@ | |
"eslint-plugin-json-files": "^4.2.0", | ||
"eslint-plugin-prefer-arrow": "^1.2.3", | ||
"eslint-plugin-sort-keys-fix": "^1.1.2", | ||
"globals": "^15.4.0", | ||
"typescript": "^5.4.5" | ||
}, | ||
"publishConfig": { | ||
"access": "public", | ||
"registry": "https://registry.npmjs.org/" | ||
} | ||
} | ||
} |
100 changes: 0 additions & 100 deletions
100
packages/eslint-config-tslint-react/lib/tslint-config-react.js
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.