Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

style: Resolve ESLint conflict with eslint-plugin-prettier #82

Merged
merged 1 commit into from
Sep 28, 2023
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
9 changes: 3 additions & 6 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,12 @@
"extends": [
"airbnb",
"airbnb/hooks",
"plugin:prettier/recommended",
"plugin:react/recommended",
"plugin:react-hooks/recommended",
"plugin:jsx-a11y/recommended",
"plugin:import/recommended"
],
"plugins": ["prettier", "react", "import", "simple-import-sort", "sort-exports"],
"plugins": ["react", "import", "simple-import-sort"],
"parserOptions": {
"ecmaFeatures": {
"jsx": true
Expand All @@ -24,8 +23,6 @@
"sourceType": "module"
},
"rules": {
"prettier/prettier": ["error"],

"react-hooks/exhaustive-deps": "warn",
"react-hooks/rules-of-hooks": "error",
"react/jsx-filename-extension": [1, { "extensions": [".js", ".jsx"] }],
Expand All @@ -50,12 +47,12 @@
"camelcase": ["warn", { "properties": "always" }],
"no-unused-vars": ["warn"],

"import/order": "off",
"import/prefer-default-export": ["warn", { "target": "any" }],
"import/no-duplicates": ["error", { "considerQueryString": true }],
"simple-import-sort/imports": "error",
"import/first": "error",
"import/newline-after-import": "error",
"sort-exports/sort-exports": ["error", { "sortDir": "asc" }]
"import/newline-after-import": "error"
},
"overrides": [
// Exceptions for ESLint related files
Expand Down
7 changes: 2 additions & 5 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,15 @@
"ms-python.autopep8",
"ms-python.flake8",
"ms-python.isort",

"njpwerner.autodocstring",

"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode",

"batisteo.vscode-django",
"monosans.djlint",
"samuelcolvin.jinjahtml",
"jota0222.multi-formatter",

"redhat.vscode-yaml"
"redhat.vscode-yaml",
"rvest.vs-code-prettier-eslint"
],
// List of extensions recommended by VS Code that should not be recommended for users of this workspace.
"unwantedRecommendations": []
Expand Down
12 changes: 6 additions & 6 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
// Javascript formatter: Prettier
"[javascript]": {
"editor.formatOnSave": true,
"editor.defaultFormatter": "esbenp.prettier-vscode"
"editor.defaultFormatter": "rvest.vs-code-prettier-eslint"
},

// CSS formatter: Styelint, PostCSS Recess Ordering.
Expand Down Expand Up @@ -204,10 +204,10 @@
"unspecified-properties-position": "bottom"
},

// Typescript formatter: Prettier
// Typescript formatter: Prettier-ESLint
"[typescript]": {
"editor.formatOnSave": true,
"editor.defaultFormatter": "esbenp.prettier-vscode"
"editor.defaultFormatter": "rvest.vs-code-prettier-eslint"
},

// Python Docstring formatter: AutoDocstring NumPy
Expand All @@ -231,21 +231,21 @@
// Jinja formatter: First done with Prettier and finalized with djLint
"[jinja]": {
"editor.defaultFormatter": "monosans.djlint",
"multiFormatter.formatterList": ["esbenp.prettier-vscode", "monosans.djlint"],
"multiFormatter.formatterList": ["rvest.vs-code-prettier-eslint", "monosans.djlint"],
"editor.detectIndentation": false,
"editor.tabSize": 2,
"editor.formatOnSave": true
},
"[jinja-html]": {
"editor.defaultFormatter": "monosans.djlint",
"multiFormatter.formatterList": ["esbenp.prettier-vscode", "monosans.djlint"],
"multiFormatter.formatterList": ["rvest.vs-code-prettier-eslint", "monosans.djlint"],
"editor.detectIndentation": false,
"editor.tabSize": 2,
"editor.formatOnSave": true
},
"[django-html]": {
"editor.defaultFormatter": "monosans.djlint",
"multiFormatter.formatterList": ["esbenp.prettier-vscode", "monosans.djlint"],
"multiFormatter.formatterList": ["rvest.vs-code-prettier-eslint", "monosans.djlint"],
"editor.detectIndentation": false,
"editor.tabSize": 2,
"editor.formatOnSave": true
Expand Down
Loading
Loading