While you can use a changeStore to accomplish the task of calling a function when you change page/etc, being able to provide a paginationStore({ onChange: () => ... }) would simplify this case.
Adding something like...
if (props?.onChange) {
state.subscribe(props.onChange)
}
...to paginationStore should work.
See discussion
While you can use a changeStore to accomplish the task of calling a function when you change page/etc, being able to provide a
paginationStore({ onChange: () => ... })would simplify this case.Adding something like...
if (props?.onChange) { state.subscribe(props.onChange) }...to paginationStore should work.
See discussion