import { createTableComponent } from '../Factory/createTableComponent';
import {
  fetch,
  update,
  deleteItem,
  setRefetch,
  deleteItemsByIds,
} from '../../stores/pwa_caches/pwa_cachesSlice';
import { loadColumns } from './configurePwa_cachesCols';
import type { PwaCache } from '../../types/entities';

const TablePwa_caches = createTableComponent<PwaCache>({
  entityName: 'pwa_caches',
  sliceSelector: (state) => state.pwa_caches,
  fetchAction: fetch,
  updateAction: update,
  deleteAction: deleteItem,
  deleteByIdsAction: deleteItemsByIds,
  setRefetchAction: setRefetch,
  loadColumnsFunction: loadColumns,
});

export default TablePwa_caches;
