-
Notifications
You must be signed in to change notification settings - Fork 9
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
feat: implemented Remix server adapter and runtime for Netlify #16
feat: implemented Remix server adapter and runtime for Netlify #16
Conversation
417c5e2
to
7809450
Compare
6929ef9
to
e141d98
Compare
Co-authored-by: Matt Kane <m@mk.gg>
I wonder what we should do about Netlify Functions. I know this is edge-only now, but presumably we'll need to move the Functions adapter in here too. I wonder if we need to plan for this in naming, structure etc |
1158976
to
a58e06e
Compare
I've taken this into account which is why the repo is remix-compute and not remix-compute-edge. And I do plan on adding the Netlify Functions post first publish of this. We could rename Definitely open to suggestions here. |
One other thing @ascorbic. I think it makes sense to have the template live here instead of in our existing repo https://github.com/netlify/remix-edge-template since this will contain both the Netlify Functions and Netlify Edge adapter/runtimes. Thoughts? |
It would make sense, but Deploy To Netlify doesn't support monorepos, so sadly not possible |
There's no Netlify Functions server runtime: it just uses the Node runtime. We could have |
@@ -38,6 +38,10 @@ export function createRequestHandler({ | |||
const loadContext = (await getLoadContext?.(request, context)) || context | |||
|
|||
const response = await remixHandler(request, loadContext) | |||
|
|||
// A useful header for debugging | |||
response.headers.set('x-nf-runtime', 'Edge') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed in #16 (comment) @ascorbic, we now have the x-nf-runtime
header.
The label-pr actions are hanging for some reason. It's not blocking anything, they've just been slow to respond the past two days on this repo for some reason. |
packages/remix-runtime/README.md
Outdated
# Remix Server Runtime for Netlify | ||
|
||
The Remix Server Runtime for Netlify is a serverless edge runtime for [Remix](https://remix.run) apps. It's built on top | ||
of [Netlify Edge Functions](https://docs.netlify.com/functions/overview/). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
of [Netlify Edge Functions](https://docs.netlify.com/functions/overview/). | |
of [Netlify Edge Functions](https://docs.netlify.com/edge-functions/overview/). |
Here we can link to the Edge Functions page of the docs instead of the Functions page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch. I thought I updated that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think like I mention below, there's an issue with latest commits not appearing on GitHub or something, because this was the README before your comments. 🤔
# Remix Server Runtime for Netlify
The Remix Server Runtime for Netlify is a serverless edge runtime for [Remix](https://remix.run) apps. It's built on top
of [Netlify Edge Functions](https://docs.netlify.com/edge-functions/overview/).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left a few minor suggestions to add some clarity and replace README URLs but otherwise READMEs good!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
READMEs look good 🚀
Co-authored-by: Stephanie <52582720+stephmarie17@users.noreply.github.com>
Description
Related Tickets & Documents
@remix-run/netlify-edge
package + update Netlify template remix-run/remix#3104Disregard the deploy failed check. I'm having issues unlinking it from the repository. It's not related to the project.
QA Instructions, Screenshots, Recordings
Local Development Steps
gh co 16
npm install
ntl build --offline
ntl serve
Testing Deployed Site
cache-control: public, max-age=31536000, s-maxage=31536000
For us to review and ship your PR efficiently, please perform the following steps:
passes our tests.
A picture of a cute animal (not mandatory, but encouraged)