bigbuffet-rw/app/soapbox/actions/bundles.ts
marcin mikołajczak ee55241792 Fix type errors, use () => RootState for getState
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2022-06-18 11:51:02 +02:00

28 lines
634 B
TypeScript

const BUNDLE_FETCH_REQUEST = 'BUNDLE_FETCH_REQUEST';
const BUNDLE_FETCH_SUCCESS = 'BUNDLE_FETCH_SUCCESS';
const BUNDLE_FETCH_FAIL = 'BUNDLE_FETCH_FAIL';
const fetchBundleRequest = (skipLoading?: boolean) => ({
type: BUNDLE_FETCH_REQUEST,
skipLoading,
});
const fetchBundleSuccess = (skipLoading?: boolean) => ({
type: BUNDLE_FETCH_SUCCESS,
skipLoading,
});
const fetchBundleFail = (error: any, skipLoading?: boolean) => ({
type: BUNDLE_FETCH_FAIL,
error,
skipLoading,
});
export {
BUNDLE_FETCH_REQUEST,
BUNDLE_FETCH_SUCCESS,
BUNDLE_FETCH_FAIL,
fetchBundleRequest,
fetchBundleSuccess,
fetchBundleFail,
};