Skip to content
Closed
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
2 changes: 1 addition & 1 deletion packages/eslint-config-react-native/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ module.exports = {
},
},

extends: ['plugin:prettier/recommended'],
extends: ['prettier'],
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://github.com/prettier/eslint-config-prettier/blob/5687e7de69ac132f053b4bc5474d5963aa3bf6d6/README.md#L7

Note that this config only turns rules off, so it only makes sense using it together with some other config.

Suggested change
extends: ['prettier'],

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suspect that people probably rely on it being turned off. So without this, the upgrade path might be too annoying / non-obvious. I think we can remove it separately later.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It feels like I’m missing something. In what situation does it help to have extends: ['prettier'] here? Remember that rules win over extends.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The assumption is that developers are using this along with recommended configs (e.g. the ones included with ESLint), so this would disable those rules.

If someone has a project in which they explicitly enable rules that are disabled by eslint-config-prettier, then yes… this would not overrule that.


plugins: [
'eslint-comments',
Expand Down
1 change: 0 additions & 1 deletion packages/eslint-config-react-native/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"eslint-plugin-eslint-comments": "^3.2.0",
"eslint-plugin-ft-flow": "^2.0.1",
"eslint-plugin-jest": "^27.9.0",
"eslint-plugin-prettier": "^4.2.1",
"eslint-plugin-react": "^7.30.1",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react-native": "^4.0.0"
Expand Down