Skip to content

Function: usePagination()

usePagination(options): object

Defined in: packages/valaxy/client/composables/post/usePagination.ts:4

Parameters

options

pageSize

number

每页数量

total

number

Post 总数

Returns

object

curPage

curPage: ComputedRef<number>

getTo()

getTo: (i) => string

Parameters

i

number

Returns

string

nextTo

nextTo: ComputedRef<string>

prevTo

prevTo: ComputedRef<string>

showNext

showNext: ComputedRef<boolean>

showPage()

showPage: (i) => boolean

Parameters

i

number

Returns

boolean

showPrev

showPrev: ComputedRef<boolean>

surLen

surLen: ComputedRef<2 | 3>

totalPages

totalPages: ComputedRef<number>