Use React.PureComponent instead of React.Component (#6653)
This commit is contained in:
parent
61e6275781
commit
13cf92df27
4 changed files with 4 additions and 4 deletions
|
@ -2,7 +2,7 @@ import React from 'react';
|
||||||
import PropTypes from 'prop-types';
|
import PropTypes from 'prop-types';
|
||||||
import { FormattedMessage } from 'react-intl';
|
import { FormattedMessage } from 'react-intl';
|
||||||
|
|
||||||
export default class ClearColumnButton extends React.Component {
|
export default class ClearColumnButton extends React.PureComponent {
|
||||||
|
|
||||||
static propTypes = {
|
static propTypes = {
|
||||||
onClick: PropTypes.func.isRequired,
|
onClick: PropTypes.func.isRequired,
|
||||||
|
|
|
@ -4,7 +4,7 @@ import PropTypes from 'prop-types';
|
||||||
const emptyComponent = () => null;
|
const emptyComponent = () => null;
|
||||||
const noop = () => { };
|
const noop = () => { };
|
||||||
|
|
||||||
class Bundle extends React.Component {
|
class Bundle extends React.PureComponent {
|
||||||
|
|
||||||
static propTypes = {
|
static propTypes = {
|
||||||
fetchComponent: PropTypes.func.isRequired,
|
fetchComponent: PropTypes.func.isRequired,
|
||||||
|
|
|
@ -13,7 +13,7 @@ const messages = defineMessages({
|
||||||
retry: { id: 'bundle_column_error.retry', defaultMessage: 'Try again' },
|
retry: { id: 'bundle_column_error.retry', defaultMessage: 'Try again' },
|
||||||
});
|
});
|
||||||
|
|
||||||
class BundleColumnError extends React.Component {
|
class BundleColumnError extends React.PureComponent {
|
||||||
|
|
||||||
static propTypes = {
|
static propTypes = {
|
||||||
onRetry: PropTypes.func.isRequired,
|
onRetry: PropTypes.func.isRequired,
|
||||||
|
|
|
@ -10,7 +10,7 @@ const messages = defineMessages({
|
||||||
close: { id: 'bundle_modal_error.close', defaultMessage: 'Close' },
|
close: { id: 'bundle_modal_error.close', defaultMessage: 'Close' },
|
||||||
});
|
});
|
||||||
|
|
||||||
class BundleModalError extends React.Component {
|
class BundleModalError extends React.PureComponent {
|
||||||
|
|
||||||
static propTypes = {
|
static propTypes = {
|
||||||
onRetry: PropTypes.func.isRequired,
|
onRetry: PropTypes.func.isRequired,
|
||||||
|
|
Loading…
Reference in a new issue