How to get the sum of a column in a table component

Hello all! Happy to report back here that tables now have a new getDisplayData() method which allows you to programmatically access any filtered data from your table in JavaScript queries (including custom columns and mapped values :tada: )

It is an async function and will not work in transformers, but in your JS query you can run

const displayedData = await yourTable.getDisplayedData()

which will return an array of objects representing the currently visible data on your table :slightly_smiling_face:

1 Like