Skip to content

Commit 3f454c6

Browse files
committed
Do not require propTypes for React components
Each react component can optionally define propTypes which is basically a schema that's used to validate input props. Despite being optional our ESLint setup requires those to be defined for each React component. This is annoying due to the following reasons: * I don't believe in type checking in dynamic languages. * There's no type schemas for third party libraries. Taking into account that contracts can be checked in tests and propTypes are checked only in development version, I suggest to do not enforce them and make them optional.
1 parent 07231b5 commit 3f454c6

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

.eslintrc.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
"jsx-a11y/anchor-is-valid": ["error", {
88
"components": ["Link"],
99
"specialLink": ["to"]
10-
}]
10+
}],
11+
"react/prop-types": [0]
1112
}
1213
}

0 commit comments

Comments
 (0)