You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a statically exported page which displays a table component with data from getStaticProps. The table will have a dropdown with two options (by year) "2020" or "2019". The default view will be "2020"; most people will only need that data.
Is there a way to do this in a way that is both a static export and which doesn't download the "2019" data for every user, i.e. only grabbing it when they select it in the dropdown?
I realize I could use getStaticPaths, but that would generate a separate page with its own table component, right? That's not what I'm looking for.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I have a statically exported page which displays a table component with data from
getStaticProps
. The table will have a dropdown with two options (by year) "2020" or "2019". The default view will be "2020"; most people will only need that data.Is there a way to do this in a way that is both a static export and which doesn't download the "2019" data for every user, i.e. only grabbing it when they select it in the dropdown?
I realize I could use
getStaticPaths
, but that would generate a separate page with its own table component, right? That's not what I'm looking for.Beta Was this translation helpful? Give feedback.
All reactions