Looking at the docs it seems like you can use getStaticProps
and getStaticPaths
as optimizations at build-time (for either static Next.js sites or SSR Next.js sites), and you're required to use getServerSideProps
for SSR.
I'm looking to support both completely static sites (i.e. no SSG/data needed @ build time/serve from nginx or S3) and SSR.
Is there any way to disable SSR completely for the static build (i.e. a build flag)? Or do I need to omit or remove these functions at build-time?