Add charts and reporting
By The Vorx Team
A chart turns a table of records into something anyone can read at a glance. The hard part isn't drawing it — it's deciding what the numbers mean and making sure the totals are the ones you think they are.
Pick the chart that answers the question
Start with the question, then choose the shape that answers it. The wrong chart hides the insight; the right one makes it obvious.
- A line chart for a trend over time, such as sales per week
- A bar chart to compare categories, such as revenue by product
- A pie or donut chart for parts of a whole, used sparingly
- A stat card for a single headline number
Add a bar chart of revenue by product category and a line chart of orders per week.
Be precise about what counts
Charts need summarised data, and the summary is where reports go wrong. Say exactly which records are included and how they're grouped:
Group orders by month and show the total value for each, counting only completed orders.
"Only completed orders" is the important half of that sentence. A total that quietly includes cancelled orders looks perfectly plausible and is perfectly wrong — and nobody notices until someone senior asks why two numbers disagree.
Make charts interactive
Static charts answer one question; interactive ones answer many.
Add a date range picker and a filter by region that update every chart on the page.
Because the filters run as a normal query against your app's own database, updates apply without leaving the page, so people can slice the numbers without a full reload.
Build a report page
A report gathers the key figures in one place people return to. Ask for a layout that reads top to bottom:
- Headline numbers first
- The most important charts grouped below
- A detailed table for anyone who wants the underlying rows
- A clear title and the date range currently in view
Create a monthly sales report page with headline totals, the two charts, and a table of orders.
That last item does more work than it looks. A chart with no visible date range is the reason two people quote different figures from the same page.
Let the numbers travel
Reports usually need to leave the app. Ask for what your team actually does with them:
Add a button to export the current report to CSV, and let me share it as a read-only link.
For a one-off pull rather than a feature, you can export any table straight to CSV from Settings → Cloud → Database.
Check the totals against something
Seed realistic data so the charts show believable shapes, then verify one number by hand — filter the underlying table to the same period and count. A chart that draws beautifully and sums incorrectly is worse than no chart, because people trust it.
If you want traffic figures rather than figures from your own data — visitors, top pages, where they came from — those arrive with every published app under Settings → Analytics, with nothing to set up.
In the docs: Analytics and Working with your database.