Skip to content

Commit

Permalink
feat(ESLint): add rules for curly braces
Browse files Browse the repository at this point in the history
  • Loading branch information
Katrin-kudryash committed Feb 22, 2024
1 parent 1d94908 commit db3f588
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 8 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module.exports = {
'plugin:@typescript-eslint/recommended',
],
parser: '@typescript-eslint/parser',
plugins: ['import', 'prettier', '@taskany/rules'],
plugins: ['import', 'prettier', '@taskany/rules', 'react'],
rules: {
'@taskany/rules/prefer-interface': 'error',
'@typescript-eslint/no-empty-function': 'off',
Expand Down Expand Up @@ -90,5 +90,12 @@ module.exports = {
],
},
],
'react/jsx-curly-brace-presence': [
'error',
{
props: 'never',
children: 'never',
},
],
},
};
2 changes: 1 addition & 1 deletion src/components/PageTitle.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export const PageTitle: React.FC<PageTitleProps> = ({ title, subtitle, info, onC

{subtitle && (
<>
{':'}
:
<StyledText as="span" size="xxl" weight="bolder" color={onClick ? gray4 : gray7} onClick={onClick}>
{subtitle}
</StyledText>
Expand Down

0 comments on commit db3f588

Please sign in to comment.