score:2

I assume that you dispatch FETCH_REQUEST action creator from your component. This component probably receives userList as a property. So this component is the best place to determine whether FETCH_REQUEST action should be dispatched.

Something like this:

class MyComponent extends React.Component {
  componentDidMount() {
    if (!this.props.userList) {
      this.props.fetchData();
    }
  }
}

...

export default connect(mapStateToProps, mapDispatchToProps)(MyComponent);

In this case you don't need to use a selector and extra condition in your saga.


Related Query

More Query from same tag