Skip to content

Project NOMAD is an offline-first knowledge and education server. Wikipedia, thousands of books, courses, maps, and optional local AI, all running on hardware you own with no internet required.

TypeScript
356 B
Raw Blame
import { useQuery } from '@tanstack/react-query'
import { FileEntry } from '../../types/files'
import api from '~/lib/api'

const useMapRegionFiles = () => {
  return useQuery<FileEntry[]>({
    queryKey: ['map-region-files'],
    queryFn: () => api.listMapRegionFiles(),
    staleTime: 5 * 60 * 1000, // 5 minutes
  })
}

export default useMapRegionFiles