I am using redux offline, and it is working correctly. But the problem is that when I make an API request offline and then come online in a few minutes, the API gets called, but if I don't come online for several hours, it doesn't call. My config is ---
import {createStore, applyMiddleware, compose} from 'redux';
import thunk from 'redux-thunk';
import {persistStore, persistReducer} from 'redux-persist';
import reducers from './reducers';
import {offline} from '@redux-offline/redux-offline';
import offlineConfig from '@redux-offline/redux-offline/lib/defaults';
import AsyncStorage from '@react-native-async-storage/async-storage';
const customConfig = {
...offlineConfig,
retry: neverRetry,
};
function neverRetry(action, attemptNumber) {
return 1000 * Math.pow(2, attemptNumber)
}
export const store = createStore(
reducers,
{},
compose(applyMiddleware(thunk), offline(customConfig)),
);
Please help me with my offline configureation also I am sending images and videos with offline api so is there a problem of storage too??