0.1.0 • Published 2 years ago

remix-aws-edge v0.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

remix-aws-edge

An adapter to run Remix on AWS CloudFront Lambda@Edge.

 


 

 


Introduction

This project exports a utility allowing you to initialise a server side request handler for Remix with the intention of being utilised against an AWS CloudFront Lambda@Edge.

 


Installation

Firstly, ensure you have the required peer dependencies installed;

npm install @remix-run/node

Then install this package;

npm install remix-aws-edge

 


Configuring your Remix project

Create a server/index.js file in the root of your Remix project with the following contents;

import { createRequestHandler } from "remix-aws-edge";

exports.handler = createRequestHandler({
  build: require("./build"),
});

 


Appreciation

This code was adapted from work performed by @ajhaining, within his remix-cloudfront-cdk-example project.