-
-
Notifications
You must be signed in to change notification settings - Fork 104
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
12 changed files
with
1,277 additions
and
1,879 deletions.
There are no files selected for viewing
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 |
---|---|---|
|
@@ -2,5 +2,4 @@ node_modules | |
*.log | ||
/.vscode | ||
.DS_Store | ||
coverage | ||
.idea |
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,4 +1 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
npx lint-staged |
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,75 @@ | ||
import globals from "globals"; | ||
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 [ | ||
{ | ||
ignores: [ | ||
"packages/java-parser/samples", | ||
"packages/prettier-plugin-java/samples", | ||
"packages/prettier-plugin-java/test-samples", | ||
"**/node_modules", | ||
"packages/prettier-plugin-java/dist", | ||
"**/babel.config.js", | ||
"website/.docusaurus" | ||
] | ||
}, | ||
...compat.extends("eslint:recommended"), | ||
{ | ||
languageOptions: { | ||
globals: { | ||
...globals.node | ||
}, | ||
ecmaVersion: 2020, | ||
sourceType: "module" | ||
}, | ||
rules: { | ||
"no-fallthrough": "off", | ||
curly: "error", | ||
"no-else-return": "error", | ||
"no-inner-declarations": "error", | ||
"no-unneeded-ternary": "error", | ||
"no-useless-return": "error", | ||
"no-console": "error", | ||
"no-var": "error", | ||
"one-var": ["error", "never"], | ||
"prefer-arrow-callback": "error", | ||
"prefer-const": "error", | ||
"react/no-deprecated": "off", | ||
strict: "error", | ||
"symbol-description": "error", | ||
yoda: [ | ||
"error", | ||
"never", | ||
{ | ||
exceptRange: true | ||
} | ||
] | ||
} | ||
}, | ||
{ | ||
files: ["packages/*/test/**/*.js"], | ||
languageOptions: { | ||
globals: { | ||
context: true, | ||
describe: true, | ||
it: true, | ||
before: true, | ||
after: true | ||
} | ||
}, | ||
rules: { | ||
strict: "off" | ||
} | ||
} | ||
]; |
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
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 |
---|---|---|
|
@@ -3,8 +3,6 @@ scripts | |
test | ||
test-samples | ||
samples | ||
coverage | ||
.nyc_output | ||
*.log | ||
src | ||
dist/test | ||
|
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
Oops, something went wrong.