Replies: 1 comment 3 replies
-
|
I guess this is potentially a duplicate of #564? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Body
Summary
A secure dev-like preview server, which is safe to broadcast for limited preview functionality
Background & Motivation
When implementing a CMS into an SSG Astro site (webhook triggered build), the clients often want a live preview of their changes. Apparently it's not safe to broadcast the dev server. However, when using the SSR adapter (activated via env variable), the whole site must be built with SSR in mind, and some convenience is lost, like returning data from
getStaticPaths.Goals
Basically just a version of the dev server which is secure to broadcast (optimization is not important, the editors don't care if page reload takes 5 or 500 ms). Functionality wise, exactly what the dev server is currently doing.
However, a very cool extra feature would be auto reload triggered from webhook, but that's totally optional.
Example
Run
npm run preview-dev(not an ideal name, butnpm run previewis already taken) on the preview server (typically a small cloud instance) with an open port.Beta Was this translation helpful? Give feedback.
All reactions