wip: refactor(client): migrate paging components to composition api

This commit is contained in:
syuilo
2022-01-14 12:02:10 +09:00
parent c8a90ec7d1
commit 45462e4a5e
3 changed files with 29 additions and 48 deletions

View File

@@ -84,19 +84,19 @@ export default defineComponent({
prev: {
endpoint: 'users/notes' as const,
limit: 10,
params: init => ({
params: computed(() => ({
userId: this.note.userId,
untilId: this.note.id,
})
})),
},
next: {
reversed: true,
endpoint: 'users/notes' as const,
limit: 10,
params: init => ({
params: computed(() => ({
userId: this.note.userId,
sinceId: this.note.id,
})
})),
},
};
},