Skip to content

useTableState: A reusable hook for server-side table state management #1668

Description

@NSTKrishna

Current Behavior

Across Meshery UI, every data table page independently declares the same set of useState calls to manage server-side pagination, search, and sort state — typically page, pageSize, search, and sortOrder. Some pages add filter state on top. This results in 4–8 identical useState lines duplicated across 8+ files :-

Expected Behavior

A reusable, framework-agnostic useTableState hook in Sistent that:

  • Manages page, pageSize, search, sortOrder, and optional custom filters state
  • Provides setter functions (setPage, setPageSize, setSearch, setSortOrder)

Environment


Contributor Guides and Resources

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions