You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
const props = defineProps<{ totalItems: number; currentPage:number; pageSize: number }>();
The component doesn't update the totalItems of course, because vue doesn't always rerender component. The composable doesn't have a method to update it tho, and I cannot pass computed ref as arguments of the composables. There is only setPage but is not enough.
How am I supposed to use this composable?
Expected behavior
A method or something to update the totalItems or be able to pass computed refs, so that the composable can react the props changing.
Steps to reproduce
Add the Pagination component to a page
pass the props to the component
update the totalItems, in real world this would mean fetch new products or something
the pagination buttons are not updating
SFUI version
@storefront-ui/vue@2.6.2
Framework
Nuxt 3
Node version
21
Browser
Chrome
OS
Mac OS
Relevant log output
No response
Able to fix / change the documentation?
Yes
No
Code of Conduct
I agree to follow this project's Code of Conduct
The text was updated successfully, but these errors were encountered:
Describe the Bug
I am passing props to this component https://docs.storefrontui.io/v2/vue/blocks/pagination
The component doesn't update the totalItems of course, because vue doesn't always rerender component. The composable doesn't have a method to update it tho, and I cannot pass computed ref as arguments of the composables. There is only setPage but is not enough.
How am I supposed to use this composable?
Expected behavior
A method or something to update the totalItems or be able to pass computed refs, so that the composable can react the props changing.
Steps to reproduce
SFUI version
@storefront-ui/vue@2.6.2
Framework
Nuxt 3
Node version
21
Browser
Chrome
OS
Mac OS
Relevant log output
No response
Able to fix / change the documentation?
Code of Conduct
The text was updated successfully, but these errors were encountered: