Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

💡 RFC: Server-Side Rendering On Demand #1119

Closed
2 of 3 tasks
ofek-a opened this issue Aug 15, 2021 · 5 comments
Closed
2 of 3 tasks

💡 RFC: Server-Side Rendering On Demand #1119

ofek-a opened this issue Aug 15, 2021 · 5 comments

Comments

@ofek-a
Copy link

ofek-a commented Aug 15, 2021

Background & Motivation

I think astro is an amazing project that will push web performance forward. What I'm mostly lacking at the moment is the ability to run astro in SSR mode and not pre-generate all the pages in advance. This current limitation is preventing me to use it in many use cases.

Proposed Solution

Possible solutions

A render API, similar to what Nuxt provides: https://nuxtjs.org/docs/2.x/internals-glossary/nuxt-render

Alternatives considered

Risks, downsides, and/or tradeoffs

Open Questions

Detailed Design

No response

Help make it happen!

  • I am willing to submit a PR to implement this change.
  • I am willing to submit a PR to implement this change, but would need some guidance.
  • I am not willing to submit a PR to implement this change.
@drwpow
Copy link
Member

drwpow commented Aug 17, 2021

RFC Call decision: we really love this idea, and think it could be useful to the Astro project as a whole. But there are a few considerations. First, we have an Astro server runtime on our list as a long-term project goal. Likely won’t happen as part of 1.0, but we’ve been designing it from day 1 to eventually support this usecase.

Short-term, I think we could probably see something implemented if it’s well-defined in scope. And to that end, I’d like to start a thread in #ideas-and-suggestions in Discord to flesh this out a bit more. Will post a link to that shortly.

@drwpow
Copy link
Member

drwpow commented Oct 5, 2021

Ah forgot to check back in! We have an #ssr channel in our Discord meant for discussing this. We are open to an RFC for this! But let’s revisit this a) when the new Vite + compiler is merged into main, and b) driven from conversations in #ssr, along with a clearer implementation of how this could be accomplished.

@drwpow drwpow closed this as completed Oct 5, 2021
@ThatGuySam
Copy link

This may not be the correct location but this also is huge for generating endpoints after the initial build, on the first page load, which is a must when static sites start approaching 5k+ pages, otherwise, you have to figure out a way to facilitate 60min+ build times, even on faster generators like Astro or Eleventy.

Netlify's max build limit is 30mins and I believe Vercel's is 60mins.

Here are some of the different approaches and respective documentation:

Netlify On-Demand Build / Distributed Persistent Rendering

Next.js Incremental Static Regeneration

Gatsby Deferred Static Generation

@alex-grover
Copy link

@drwpow sorry for reviving this old issue, but I'm not on Discord. Now that Astro has SSR, is this something that's in discussion? This feature is extremely useful in other frameworks.

@davidmyersdev
Copy link

For others that are looking for info about ISR in Astro: withastro/roadmap#698

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants