Skip to content

Programmatically change current page #662

Closed
@josueuitzil

Description

@josueuitzil

Hi team, I have a question regarding the page prop of the table. If I pass this prop to the component and then update its value, then only the pagination will get updated. You can test it in the following sandbox: https://codesandbox.io/s/material-table-starter-template-forked-n8epbv?file=/src/index.js

From the name of the prop I initially thought that it could be used to programmatically change the current page of the table, however, I couldn't find documentation on this prop so I'm not sure if this is expected behavior or a bug.

Is there any other way that the current page could be changed from outside the table? I think that passing a ref to the table and then using it to directly call the dataManager methods could work but seems a little hacky.

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requestedwontfixThis will not be worked on

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions