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

0.23.0 release branch (SSR) #868

Merged
merged 9 commits into from
Feb 12, 2022
Merged

0.23.0 release branch (SSR) #868

merged 9 commits into from
Feb 12, 2022

Conversation

thescientist13
Copy link
Member

@thescientist13 thescientist13 commented Jan 14, 2022

Related Issue

resolves #708 (continuation of #838 )

Summary of Changes

  1. Introduction of Server Side Rendering
  2. Introduced a new Renderer plugin for custom SSR handling
  3. Created a new package for doing SSR w/Lit
  4. Add support for hybrid workspaces
  5. Introduce interpolateFrontmatter configuration
  6. Website copy and content updates
  7. Release blog post

Alpha Release Test Plan

I think given the impact of this change, it would be wise for us to cut from a release branch instead of merging right into main so that

  • we can test this in the wild first and ensure all our docs / examples / refactoring is correct
  • we're not stuck with broken code in master while under pressure to fix things

The plan would be to test against the following projects / workflows as alpha releases are iterated upon:

  1. greenwood-getting-started - upgrade greenwood v0.23.0 greenwood-getting-started#57
  2. projectevergreen.github.io - upgrade greenwood v0.23.0 projectevergreen.github.io#79
  3. thegreehouse.io - upgrade greenwood v0.23.0 thegreenhouseio/www.thegreenhouse.io#260
  4. contributary.community - upgrade greenwood v0.23.0 ContributaryCommunity/www.contributary.community#105
  5. analogstudios.net - upgrade greenwood v0.23.0 AnalogStudiosRI/www.analogstudios.net#71
  6. greenwood-starter-presentation - upgrade greenwood v0.23.0 thescientist13/greenwood-starter-presentation#54
  7. npx
  8. Stackblitz

This PR should NOT be squashed merged though when merging into master.

TODOs

  1. Add support for additional (SSR) rendering options through a render plugin type #709
  2. Create a Lit based render plugin that provides Lit based SSR #710
  3. alpha.0
  4. have Greenwood auto detect project (mode) and expose client router option ("fluid" workspaces) #856
  5. Custom port option for (prod) server
  6. alpha.1
  7. website copy updates (now that we're more than just SSG) + Website redesign, branding, and long term structure #503 (comment)
  8. SSR guide (using Vercel or AWS or Heoruku?) - will use Analog Studios project as a full fledged case study (taking Web Components to the edge!) - Hybrid Architecture (Serveless, Incremental, SSR) AnalogStudiosRI/www.analogstudios.net#37
  9. Release blog post - release v0.23.0 blog post #873
    • call out experimental disclaimer / limitation notes, add link to GitHub issues filter

Nice To Have (else make new issue)

  1. static export option for SSR routes - notes from Sveltekit team on this from their own implementation analysis - Should have the ability to statically export server rendered routes as just HTML #879
  2. nested dynamic routes, e.g. /artist/${id} - Server side routes should support dynamic route naming (with prerendering) #882
  3. (investigate) static rendering w/ custom renderer, e.g. www/ + Lit (just have experimental support right now) and define patterns / practices - support resource plugin based transformations for standard module formats (ex: import JSON, CSS) for SSR #878 (comment)
  4. (investigate) hydration support for SSG & SSR (how do we get the data in an SSG context though... ?)
  5. (investigate) streaming support for HTML via generators would be awesome! - Serverless (+ single route builds) #626 (comment)
  6. make prerender config option false by default #855 - support resource plugin based transformations for standard module formats (ex: import JSON, CSS) for SSR #878
  7. TypeScript support for routes / non resources - support resource plugin based transformations for standard module formats (ex: import JSON, CSS) for SSR #878 (comment)
  8. Resource plugins wont work with (custom?) SSR, I think NodeJS has support for custom loaders, so maybe need to tap into that - support resource plugin based transformations for standard module formats (ex: import JSON, CSS) for SSR #878
  9. Prebundle / resuse bundle for SSR routes instead of running Rollup on every SSR request - avoid Rollup double bundling for pre-bundled static assets for server routes #883
  10. Review "meta" adjacent issues or tie into - Favor Content over Code / Configuration (ex. metadata) #851 and some sort of static templating - Server Side Rendering and Templating (puppeteer alternatives) #576 (comment)

* initial introduction of server side rendering

* update config spec

* ESM cache busting in development with workers

* correctly establish body and template support for SSR routes

* basic metadata support

* frontmatter and graph support

* fix lint

* basic smoke test case for SSR

* fix and clean up specs

* basic smoke testing with HTML optimization for server routes

* handle pre-rendering for SSR routes

* support SSR bundling

* full frontmatter support and custom route data for SSR routes

* document server rendering

* add ssr mode to config docs

* clarify serve command in README

* ESM path to file interop for windows

* rebase fixes

* remove demo code
@thescientist13 thescientist13 added RFC Proposal and changes to workflows, architecture, APIs, etc documentation Greenwood specific docs CLI SSR discussion tied to an ongoing discussion or meeting notes feature New feature or request labels Jan 14, 2022
@thescientist13 thescientist13 added this to the 1.0 milestone Jan 14, 2022
@thescientist13 thescientist13 self-assigned this Jan 14, 2022
* POC of Lit SSR for development

* render lit SSR from html

* add renderer API to Greenwood

* mini refactor

* stub out lit renderer plugin

* build and serve support

* update specs

* fix incorrect callback assignment

* refactor SSR worker for Greenwood as a plugin

* support for intercepting and optimizing SSR routes and add dual SSR support for plugins

* template support for SSR routes

* set prerender true in spec

* add minimumal support for using custom renderer to prerender static pages

* lit render SSR specs

* address spec TODOs

* fix specs

* SSR specs for development

* documentation for custom renderer plugin

* remove puppeteer prerendering option from SSR routes and ensure explicit SSR output for lit renderer

* remove demo code
* refactor SSG and SSR modes

* refactor out mode completely and introduce staticRouter

* hybrid documentation updates and remove mode configuration docs

* rename specs
* implement interpolateFrontmatter feature and add specs

* docs for interpolate config
* home page and banner copy updates

* about page updates and revisions

* update and revisit docs pages

* update and revisit getting started pages

* refreah plugins and guides pages

* big round of spellchecking

* underline and darken home page links

* spellcheck package READMEs

* update project description in packages and README, and meta

* add link on static and server rendering stratigies and remove extra plugin from docs greenwood config

* update project README content
* release v0.23.0 blog post

* PR feedback, fix typos, update issues link filter
@thescientist13 thescientist13 marked this pull request as ready for review February 12, 2022 00:44
@thescientist13 thescientist13 merged commit d0914be into master Feb 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment