We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6d3e666 commit dbe7e15Copy full SHA for dbe7e15
src/util/getElementType.js
@@ -20,9 +20,7 @@ const getElementType = (context: ESLintContext): ((node: JSXOpeningElement) => s
20
21
let rawType = elementType(node);
22
if (polymorphicProp) {
23
- if (!polymorphicAllowList) {
24
- rawType = polymorphicProp;
25
- } else if (polymorphicAllowList.includes(rawType)) {
+ if (!polymorphicAllowList || polymorphicAllowList.includes(rawType)) {
26
rawType = polymorphicProp;
27
}
28
0 commit comments