@greenwood/plugin-adapter-aws
v0.34.0
Published
A Greenwood plugin for supporting AWS serverless and edge runtimes.
Maintainers
Readme
@greenwood/plugin-adapter-aws
Overview
Enables usage of AWS hosting for API routes and SSR pages. For more information and complete docs on Greenwood, please visit our website.
This package assumes you already have
@greenwood/cliinstalled.
Features
This plugin "adapts" SSR pages and API routes to be compatible with AWS Lambda and ready to use with IaC (Infrastructure as Code) tools like SST and Architect.
Note: You can see a working example of this plugin here.
Installation
You can use your favorite JavaScript package manager to install this package.
# npm
$ npm i -D @greenwood/plugin-adapter-aws
# yarn
$ yarn add @greenwood/plugin-adapter-aws --dev
# pnpm
$ pnpm add -D @greenwood/plugin-adapter-awsUsage
Add this plugin to your greenwood.config.js:
import { greenwoodPluginAdapterAws } from '@greenwood/plugin-adapter-aws';
export default {
// ...
plugins: [
greenwoodPluginAdapterAws()
]
}Types
Types should automatically be inferred through this package's exports map, but can be referenced explicitly in both JavaScript (JSDoc) and TypeScript files if needed.
/** @type {import('@greenwood/plugin-adapter-aws').AwsAdapter} */import type { AwsAdapter } from '@greenwood/plugin-adapter-aws';