1.1.1 • Published 5 years ago

with-load-data v1.1.1

Weekly downloads
2
License
MPL-2.0
Repository
github
Last release
5 years ago

HOC withLoadData

Send Redux action to load data, and return null instead wrapped Component until check function returns true

Usage:

    withLoadData({
        actionLoadData,
        checkIsDataLoaded,
    })(Component)
  • HOC connect component to Redux store
  • actionLoadData({ componentProps }) will bind to redux dispatch, so it can be regular Redux action and pass component props to action
  • checkIsDataLoaded receive state as a param, so we have access to redux state
1.1.1

5 years ago

1.1.0

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago