Skip to content

enjikaka/react-service-worker-components

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-service-worker-components

A demo of rendering React Server Components in a Service Worker.

I've previously done some experiments rendering HTML (web components) with data from a JSON API in the Service Worker, to avoid additional services on the server aside of the main API. Surely, it has it's pros and cons. One nice thing is that you can still "server side render" user-unique data that cannot be cached on your server, but can be locally in the server worker after genration - provided that your API provides cache headers for API resources so you know when to invalidate. You can also utilize that most clients todays are thick rather than thin, and use their processing power instead of paying for your expensive hipster server software.

About

React Server Components, but they are rendered in a Service Worker...

Topics

Resources

Stars

Watchers

Forks