Files
freeCodeCamp/common/app/components/NotFound/index.jsx

23 lines
489 B
JavaScript
Raw Normal View History

2015-11-19 22:45:31 -08:00
import React, { PropTypes } from 'react';
import { connect } from 'react-redux';
import { hardGoTo } from '../../redux/actions';
2015-11-19 22:45:31 -08:00
export class NotFound extends React.Component {
2016-01-27 11:34:44 -08:00
static displayName = 'NotFound';
static propTypes = {
location: PropTypes.object,
hardGoTo: PropTypes.func
2016-01-27 11:34:44 -08:00
};
2015-11-19 22:45:31 -08:00
componentWillMount() {
this.props.hardGoTo(this.props.location.pathname);
2016-01-27 11:34:44 -08:00
}
2015-11-19 22:45:31 -08:00
render() {
return <span></span>;
}
2016-01-27 11:34:44 -08:00
}
export default connect(null, { hardGoTo })(NotFound);