Custom States vs Hide/Unhide

Hi everyone,

I have a bunch of tables and charts on five separate pages and would like to now have them on a single page. It will be more of an interface whereby the user clicks on either one of five buttons, and the presented data changes.

The vast majority of the data is stored in the DB but some are calculations which take place via an external API. These calculations take some time to load, so am inclined to use custom states as I could then kick start the calculation when the user is viewing the other sets of data on the page i.e., before they’ve selected to view the calculated data.

More broadly however I’m wondering, which would offer the better performance:

  1. To use custom states
  2. To have each of the five sets of data in separate groups which hide/unhide as the user clicks on the respective button

If the latter, then would it also be possible to have the calculations via API take place in the background, like one could using a custom state?

Many thanks in advance!

This topic was automatically closed after 70 days. New replies are no longer allowed.