mirror of
https://github.com/GiriNeko/YesPlayMusic.git
synced 2025-12-17 13:48:02 +00:00
refactor: 将 enum key的格式改为 PascalCase
This commit is contained in:
parent
0061a66124
commit
7e892997bd
36 changed files with 141 additions and 142 deletions
|
|
@ -1,12 +1,12 @@
|
|||
import { FetchTracksParams, TrackApiNames } from '@/shared/api/Track'
|
||||
import { fetchTracks } from 'api/track'
|
||||
import { fetchTracks } from '../api/track'
|
||||
|
||||
// 100 tracks each page
|
||||
const offset = 100
|
||||
|
||||
export default function useTracksInfinite(params: FetchTracksParams) {
|
||||
return useInfiniteQuery(
|
||||
[TrackApiNames.FETCH_TRACKS, params],
|
||||
[TrackApiNames.FetchTracks, params],
|
||||
({ pageParam = 0 }) => {
|
||||
const cursorStart = pageParam * offset
|
||||
const cursorEnd = cursorStart + offset
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue