mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-08-03 01:21:54 +00:00
Moved propTypes and defaultProps as static properties in class components
This commit is contained in:
@@ -9,13 +9,13 @@ import { createShortUrlResultType } from '../reducers/shortUrlCreationResult';
|
||||
import { stateFlagTimeout } from '../../utils/utils';
|
||||
import './CreateShortUrlResult.scss';
|
||||
|
||||
const propTypes = {
|
||||
resetCreateShortUrl: PropTypes.func,
|
||||
error: PropTypes.bool,
|
||||
result: createShortUrlResultType,
|
||||
};
|
||||
|
||||
export default class CreateShortUrlResult extends React.Component {
|
||||
static propTypes = {
|
||||
resetCreateShortUrl: PropTypes.func,
|
||||
error: PropTypes.bool,
|
||||
result: createShortUrlResultType,
|
||||
};
|
||||
|
||||
state = { showCopyTooltip: false };
|
||||
|
||||
componentDidMount() {
|
||||
@@ -62,5 +62,3 @@ export default class CreateShortUrlResult extends React.Component {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
CreateShortUrlResult.propTypes = propTypes;
|
||||
|
||||
Reference in New Issue
Block a user