How use sortable table with API data source?

I am getting data via API and displaying in a table via Data View. Can I make columns sortable? In my case, there is no server component, as in the example in the documentation. I use Bootstrap5 generator.

You can. The dataview has sort capability on the browser client so no server is required

To add on to @scalaris answer, I would look at the API documentation as well, sometimes API has sorting, pagination and limit on their GET request.

Or better still, use tabulator tables.

1 Like

Yes, I see that there is such a parameter in the Data View, but there is only one. And what is the best way to make it so that the user can change the column and sort direction himself?

The Wappler Wizard will set it all up for you. Just make sure to bind the sort/sir parameters to the data view as the final step. I believe there’s an example in the documentation

in the documentation and examples, I found only the option with Server Connect, but how to enable sorting in wizzard in the case of Data View and API is not clear.

The APi and server connect data sources are interchangeable in the wizard. Pipe it through a dataview and use that in the wizard

That’s what I;m doing, do I need to include this standard sorting flag in the settings?

You need to set the state manager (and a cookie manager to the page) and the sort and order parameters.