Making propTypes static

This commit is contained in:
Jeff Avallone
2019-01-13 21:30:06 -05:00
parent bf44bce954
commit 7261b0b526
5 changed files with 25 additions and 25 deletions
+5 -5
View File
@@ -5,17 +5,17 @@ import * as Sentry from '@sentry/browser';
import SentryError from 'components/SentryError';
class SentryBoundary extends React.Component {
state = {
hasError: false
}
propTypes = {
static propTypes = {
children: PropTypes.oneOfType([
PropTypes.arrayOf(PropTypes.node),
PropTypes.node
]).isRequired
}
state = {
hasError: false
}
static getDerivedStateFromError() {
return { hasError: true };
}