-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplified lint configurations (#148)
* refactor: Consumed base configurations * refactor: Consumed shared configurations * bugfix: Pinned get-tsconfig to address a regression in v4.7.4 Error while loading rule '...': File '@tsconfig/strictest/tsconfig' not found. * chore: Directly consumed @tsconfig/* to avoid pinning get-tsconfig * chore: Ignored lint errors * chore: Added lockfile * chore: Added changeset --------- Co-authored-by: ijlee2 <[email protected]>
- Loading branch information
Showing
57 changed files
with
145 additions
and
485 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,12 @@ | ||
--- | ||
"@codemod-utils/ast-javascript": patch | ||
"@codemod-utils/ast-template": patch | ||
"@codemod-utils/blueprints": patch | ||
"@codemod-utils/ember": patch | ||
"@codemod-utils/files": patch | ||
"@codemod-utils/tests": patch | ||
"@codemod-utils/json": patch | ||
"@codemod-utils/cli": patch | ||
--- | ||
|
||
Simplified lint configurations |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
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,96 +1 @@ | ||
import babelEslintParser from '@babel/eslint-parser'; | ||
import eslint from '@eslint/js'; | ||
import eslintPluginImport from 'eslint-plugin-import'; | ||
import eslintPluginN from 'eslint-plugin-n'; | ||
import eslintPluginPrettier from 'eslint-plugin-prettier/recommended'; | ||
import eslintPluginSimpleImportSort from 'eslint-plugin-simple-import-sort'; | ||
import globals from 'globals'; | ||
|
||
const parserOptionsJs = { | ||
babelOptions: { | ||
plugins: [ | ||
[ | ||
'@babel/plugin-proposal-decorators', | ||
{ | ||
decoratorsBeforeExport: true, | ||
}, | ||
], | ||
], | ||
}, | ||
ecmaFeatures: { | ||
modules: true, | ||
}, | ||
ecmaVersion: 'latest', | ||
requireConfigFile: false, | ||
}; | ||
|
||
export default [ | ||
{ | ||
ignores: [ | ||
'dist/', | ||
'dist-for-testing/', | ||
'node_modules/', | ||
'src/blueprints/', | ||
'tests/fixtures/', | ||
'tmp/', | ||
'!.*', | ||
'.*/', | ||
], | ||
}, | ||
{ | ||
linterOptions: { | ||
reportUnusedDisableDirectives: 'error', | ||
}, | ||
}, | ||
{ | ||
plugins: { | ||
'simple-import-sort': eslintPluginSimpleImportSort, | ||
}, | ||
rules: { | ||
curly: 'error', | ||
'simple-import-sort/imports': 'error', | ||
'simple-import-sort/exports': 'error', | ||
}, | ||
}, | ||
|
||
eslint.configs.recommended, | ||
eslintPluginImport.flatConfigs.recommended, | ||
eslintPluginPrettier, | ||
|
||
// JavaScript files | ||
{ | ||
files: ['**/*.js'], | ||
languageOptions: { | ||
parser: babelEslintParser, | ||
parserOptions: parserOptionsJs, | ||
}, | ||
rules: { | ||
'import/no-duplicates': 'error', | ||
}, | ||
}, | ||
|
||
// Configuration files | ||
{ | ||
files: ['**/*.cjs'], | ||
languageOptions: { | ||
ecmaVersion: 'latest', | ||
globals: globals.node, | ||
sourceType: 'script', | ||
}, | ||
plugins: { | ||
n: eslintPluginN, | ||
}, | ||
}, | ||
{ | ||
files: ['**/*.mjs'], | ||
languageOptions: { | ||
ecmaVersion: 'latest', | ||
globals: globals.node, | ||
parserOptions: parserOptionsJs, | ||
sourceType: 'module', | ||
}, | ||
plugins: { | ||
n: eslintPluginN, | ||
}, | ||
}, | ||
]; | ||
export { default } from '@ijlee2-frontend-configs/eslint-config-node/javascript'; |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default } from '@ijlee2-frontend-configs/prettier'; |
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.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default } from '@ijlee2-frontend-configs/prettier'; |
This file was deleted.
Oops, something went wrong.
3 changes: 2 additions & 1 deletion
3
configs/typescript/node18/tsconfig.json → configs/typescript/node18/index.json
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,7 +1,8 @@ | ||
{ | ||
"extends": ["@tsconfig/node18/tsconfig", "@tsconfig/strictest/tsconfig"], | ||
"compilerOptions": { | ||
"moduleResolution": "NodeNext", | ||
"module": "nodenext", | ||
"moduleResolution": "nodenext", | ||
"verbatimModuleSyntax": 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 |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default } from '@ijlee2-frontend-configs/prettier'; |
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.
This file was deleted.
Oops, something went wrong.
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 @@ | ||
export { default } from '@shared-configs/eslint-config-node/typescript'; |
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 @@ | ||
export { default } from '@shared-configs/prettier'; |
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.
This file was deleted.
Oops, something went wrong.
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 @@ | ||
export { default } from '@shared-configs/eslint-config-node/typescript'; |
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 @@ | ||
export { default } from '@shared-configs/prettier'; |
Oops, something went wrong.