Skip to content

Commit

Permalink
Remove displayName property
Browse files Browse the repository at this point in the history
Signed-off-by: Jan Potoms <[email protected]>
  • Loading branch information
Janpot authored Oct 18, 2024
1 parent 7e3e341 commit 710c10e
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ export const removePropTypesPlugin = declare<{}>((api) => {
const property = left.get('property');
const isPropTypes = property.isIdentifier({ name: 'propTypes' });
const isMuiName = property.isIdentifier({ name: 'muiName' });
const isDisplayName = property.isIdentifier({ name: 'displayName' });

if (!isPropTypes && !isMuiName) {
if (!isPropTypes && !isMuiName && !isDisplayName) {
return;
}
const parentExpression = path.findParent((p) => p.isExpressionStatement());
Expand Down

0 comments on commit 710c10e

Please sign in to comment.