code: function useResources(createQueries, queriesToSubscribe) {
    const states = createQueries.map(function (createQuery, index) {
      return queriesToSubscribe[index] ? // eslint-disable-next-line react-hooks/rules-of-hooks
      useRetrieveResourceAndSubscribe(createQuery) : // eslint-disable-next-line react-hooks/rules-of-hooks
      useRetrieveResource(createQuery);
    });
    const nonFetchedStates = states.filter(function (state) {
      return !state.fetched;
    });
  
    if (nonFetchedStates.length !== 0) {
      return [true, []];
    }
  
    return [false, states.map(function (state) {
      return state.result;
    })];
  }
docs: /* eslint-disable import/export