mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 05:40:31 +00:00
refactor: HOCs named imports
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
import { connect } from 'react-redux';
|
||||
import { getCurrentOrganizationFactory } from '@/store/authentication/authentication.selectors';
|
||||
|
||||
export default (mapState) => {
|
||||
export const withCurrentOrganization = (mapState) => {
|
||||
const getCurrentOrganization = getCurrentOrganizationFactory();
|
||||
|
||||
const mapStateToProps = (state, props) => {
|
||||
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
isOrganizationBuildRunningFactory
|
||||
} from '@/store/organizations/organizations.selectors';
|
||||
|
||||
export default (mapState) => {
|
||||
export const withOrganization = (mapState) => {
|
||||
const getOrganizationById = getOrganizationByIdFactory();
|
||||
const isOrganizationReady = isOrganizationReadyFactory();
|
||||
const isOrganizationBuilt = isOrganizationBuiltFactory();
|
||||
|
||||
@@ -9,4 +9,4 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
dispatch(setOrganizationSetupCompleted(congrats)),
|
||||
});
|
||||
|
||||
export default connect(null, mapDispatchToProps);
|
||||
export const withOrganizationActions = connect(null, mapDispatchToProps);
|
||||
|
||||
Reference in New Issue
Block a user