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

[SIEM] Enable eslint react/no-children-prop #53985

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.js
Original file line number Diff line number Diff line change
Expand Up @@ -729,15 +729,13 @@ module.exports = {
'no-unreachable': 'error',
'no-unsafe-finally': 'error',
'no-useless-call': 'error',
// This will be turned on after bug fixes are mostly complete
// 'no-useless-catch': 'warn',
'no-useless-catch': 'error',
'no-useless-concat': 'error',
'no-useless-computed-key': 'error',
// This will be turned on after bug fixes are mostly complete
// 'no-useless-escape': 'warn',
'no-useless-rename': 'error',
// This will be turned on after bug fixes are mostly complete
// 'no-useless-return': 'warn',
'no-useless-return': 'error',
// This will be turned on after bug fixers are mostly complete
// 'no-void': 'warn',
'one-var-declaration-per-line': 'error',
Expand All @@ -751,8 +749,7 @@ module.exports = {
'react/button-has-type': 'error',
'react/forbid-dom-props': 'error',
'react/no-access-state-in-setstate': 'error',
// This style will be turned on after most bugs are fixed
// 'react/no-children-prop': 'warn',
'react/no-children-prop': 'error',
'react/no-danger-with-children': 'error',
'react/no-deprecated': 'error',
'react/no-did-mount-set-state': 'error',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,9 @@ export const DefaultDraggable = React.memo<DefaultDraggableType>(
<Provider dataProvider={dataProvider} />
</DragEffects>
) : (
<Content
children={children}
field={field}
tooltipContent={tooltipContent}
value={value}
/>
<Content field={field} tooltipContent={tooltipContent} value={value}>
{children}
</Content>
)
}
/>
Expand Down