diff --git a/packages/strapi-generate-plugin/files/admin/src/containers/App/index.js b/packages/strapi-generate-plugin/files/admin/src/containers/App/index.js index bfc2ee0790..bf3512396b 100755 --- a/packages/strapi-generate-plugin/files/admin/src/containers/App/index.js +++ b/packages/strapi-generate-plugin/files/admin/src/containers/App/index.js @@ -10,7 +10,7 @@ import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import { createStructuredSelector } from 'reselect'; import { Switch, Route } from 'react-router-dom'; -import { compose } from 'redux'; +import { bindActionCreators, compose } from 'redux'; import HomePage from 'containers/HomePage'; @@ -28,14 +28,19 @@ class App extends React.Component { } } -App.propTypes = { - match: PropTypes.object, +App.contextTypes = { + plugins: PropTypes.object, + router: PropTypes.object.isRequired, + updatePlugin: PropTypes.func, }; +App.propTypes = {}; + export function mapDispatchToProps(dispatch) { - return { + return bindActionCreators( + {}, dispatch, - }; + ); } const mapStateToProps = createStructuredSelector({}); diff --git a/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/index.js b/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/index.js index 8f78d2f939..c213d57414 100755 --- a/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/index.js +++ b/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/index.js @@ -68,10 +68,9 @@ HomePage.propTypes = { data: PropTypes.oneOfType([ PropTypes.bool, PropTypes.object, - ]), - exposedComponents: PropTypes.object, - loadData: PropTypes.func, - loading: PropTypes.bool, + ]).isRequired, + loadData: PropTypes.func.isRequired, + loading: PropTypes.bool.isRequired, }; function mapDispatchToProps(dispatch) { diff --git a/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/saga.js b/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/saga.js index 4d32b94f38..82504e76f3 100755 --- a/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/saga.js +++ b/packages/strapi-generate-plugin/files/admin/src/containers/HomePage/saga.js @@ -1,6 +1,5 @@ -import { takeLatest } from 'redux-saga'; import { LOCATION_CHANGE } from 'react-router-redux'; -import { put, fork, take, cancel } from 'redux-saga/effects'; +import { takeLatest, put, fork, take, cancel } from 'redux-saga/effects'; import { loadedData } from './actions'; import { LOAD_DATA } from './constants'; diff --git a/packages/strapi-generate-plugin/json/package.json.js b/packages/strapi-generate-plugin/json/package.json.js index 0225513d41..1b9ead3c27 100755 --- a/packages/strapi-generate-plugin/json/package.json.js +++ b/packages/strapi-generate-plugin/json/package.json.js @@ -43,7 +43,7 @@ module.exports = scope => { }, 'dependencies': {}, 'devDependencies': { - 'strapi-helper-plugin': '3.0.0-alpha.4.8' + 'strapi-helper-plugin': '3.0.0-alpha.6.3' }, 'author': { 'name': scope.author || 'A Strapi developer',