Initial commit
This commit is contained in:
commit
7878e653a0
253 changed files with 24552 additions and 0 deletions
23
src/components/EditProject/EditProjectReduxWrapper.tsx
Normal file
23
src/components/EditProject/EditProjectReduxWrapper.tsx
Normal file
|
@ -0,0 +1,23 @@
|
|||
import { connect } from 'react-redux';
|
||||
import { bindActionCreators } from 'redux';
|
||||
import { projectUpdate } from '../../redux/actions/projects';
|
||||
import EditProject from './EditProject';
|
||||
import State from '../../redux/state';
|
||||
import { currentProject } from '../../redux/selectors/projects';
|
||||
|
||||
function mapStateToProps(state: State) {
|
||||
return {
|
||||
project: currentProject(state),
|
||||
};
|
||||
}
|
||||
|
||||
function mapDispatchToProps(dispatch: any) {
|
||||
return bindActionCreators(
|
||||
{
|
||||
onProjectChange: projectUpdate,
|
||||
},
|
||||
dispatch,
|
||||
);
|
||||
}
|
||||
|
||||
export default connect(mapStateToProps, mapDispatchToProps)(EditProject);
|
Loading…
Add table
Add a link
Reference in a new issue