Skip to content

Commit

Permalink
revert
Browse files Browse the repository at this point in the history
  • Loading branch information
Janpot committed Nov 10, 2022
1 parent da2fb83 commit a091c9d
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 4 deletions.
1 change: 1 addition & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,7 @@ module.exports = {
'react/require-default-props': 'off',
'react/state-in-constructor': 'off',
'react/static-property-placement': 'off',
'react/function-component-definition': 'off',
},
},
{
Expand Down
1 change: 0 additions & 1 deletion packages/mui-styles/src/makeStyles/makeStyles.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import { createStyles, makeStyles } from '@mui/styles';
message: string;
}

// eslint-disable-next-line react/function-component-definition
const MyComponent = (props: MyComponentProps) => {
const { color, message } = props;
// @ts-expect-error Expected 1 argument, but got 0
Expand Down
3 changes: 0 additions & 3 deletions packages/mui-styles/test/styles.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,6 @@ withStyles((theme) =>
},
});

// eslint-disable-next-line react/function-component-definition
const Component = (props: ComponentProps) => {
return <div className={props.classes.content}>Hello {props.caption}</div>;
};
Expand Down Expand Up @@ -370,10 +369,8 @@ withStyles((theme) =>

const StyledMyButton = withStyles(styles)(MyButton);

// eslint-disable-next-line react/function-component-definition
const CorrectUsage = () => <StyledMyButton nonDefaulted="2" />;
// @ts-expect-error Property 'nonDefaulted' is missing in type '{}'
// eslint-disable-next-line react/function-component-definition
const MissingPropUsage = () => <StyledMyButton />;
}

Expand Down

0 comments on commit a091c9d

Please sign in to comment.