diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2020-06-02 16:20:01 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2020-06-02 16:20:01 +0200 |
| commit | 3b00ca8991f7092aa1cb3d584df12a0368f4fa4b (patch) | |
| tree | 47efdb9f7dbbd226fd7c43111e7e052467f47618 /frontend/views/index/containers/graph.index.js | |
| parent | 2db55c3d261ddee52019bbd06dc5f6545db39c16 (diff) | |
form works! add graph reducer, fonts
Diffstat (limited to 'frontend/views/index/containers/graph.index.js')
| -rw-r--r-- | frontend/views/index/containers/graph.index.js | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/frontend/views/index/containers/graph.index.js b/frontend/views/index/containers/graph.index.js index b18c768..7ac31da 100644 --- a/frontend/views/index/containers/graph.index.js +++ b/frontend/views/index/containers/graph.index.js @@ -3,11 +3,23 @@ import { Link } from 'react-router-dom' import { bindActionCreators } from 'redux' import { connect } from 'react-redux' -// import actions from '../../actions' +import { Loader } from '../../../common' +import actions from '../../../actions' // import * as uploadActions from './upload.actions' class GraphIndex extends Component { + componentDidMount() { + actions.graph.index() + } render() { + const { index } = this.props + if (index.loading) { + return ( + <div className='graphIndex'> + <Loader /> + </div> + ) + } return ( <div className='graphIndex'> <b>welcome, swimmer</b> @@ -18,7 +30,7 @@ class GraphIndex extends Component { } const mapStateToProps = state => ({ - // upload: state.upload, + index: state.graph.index, }) const mapDispatchToProps = dispatch => ({ |
