Skip to content

Commit 68cdc59

Browse files
lencioniljharb
authored andcommitted
[eslint config] [new] Enable react/jsx-closing-tag-location
1 parent f1cc91c commit 68cdc59

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

Diff for: packages/eslint-config-airbnb/rules/react.js

+2-3
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,8 @@ module.exports = {
4949
'react/jsx-closing-bracket-location': ['error', 'line-aligned'],
5050

5151
// Validate closing tag location in JSX
52-
// https://github.com/yannickcr/eslint-plugin-react/blob/9e13ae2c51e44872b45cc15bf1ac3a72105bdd0e/docs/rules/jsx-closing-tag-location.md
53-
// TODO: enable, semver-minor
54-
'react/jsx-closing-tag-location': 'off',
52+
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-closing-tag-location.md
53+
'react/jsx-closing-tag-location': 'error',
5554

5655
// Enforce or disallow spaces inside of curly braces in JSX attributes
5756
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-curly-spacing.md

Diff for: react/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@
165165

166166
## Alignment
167167

168-
- Follow these alignment styles for JSX syntax. eslint: [`react/jsx-closing-bracket-location`](https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-closing-bracket-location.md)
168+
- Follow these alignment styles for JSX syntax. eslint: [`react/jsx-closing-bracket-location`](https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-closing-bracket-location.md) [`react/jsx-closing-tag-location`](https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-closing-tag-location.md)
169169

170170
```jsx
171171
// bad

0 commit comments

Comments
 (0)