Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ara-framework/hypernova-lambda
Implementation of Hypernova for AWS Lambda
https://github.com/ara-framework/hypernova-lambda
aws-lambda hypernova
Last synced: 4 days ago
JSON representation
Implementation of Hypernova for AWS Lambda
- Host: GitHub
- URL: https://github.com/ara-framework/hypernova-lambda
- Owner: ara-framework
- License: mit
- Created: 2019-02-23T19:07:38.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2021-04-29T20:23:45.000Z (over 3 years ago)
- Last Synced: 2024-12-14T17:50:16.435Z (24 days ago)
- Topics: aws-lambda, hypernova
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/hypernova-lambda
- Size: 10.7 KB
- Stars: 9
- Watchers: 3
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Hypernova Lambda
Implementation of [Hypernova](https://github.com/airbnb/hypernova) for [AWS Lambda](https://aws.amazon.com/lambda/)
## Differences of Hypernova Server
**Hypernova Lambda** uses [Amazon API Gateway](https://aws.amazon.com/api-gateway/) instead of [express](https://expressjs.com/) as HTTP Server and the Server Side Rendering will be perform by the Lambda Function.
### Options for Hypernova Lambda
The only supported option for Hypernova Lambda is `getComponent` and `processJobsConcurrently` is `true` by default so all the job will be proccessed concurrently.
```js
{
getComponet: undefined
}
```## Installation
```sh
npm install --save hypernova-lambda hypernova
```## Example
```js
import hypernova from 'hypernova-lambda';const getComponent = (name) => {
if (name === 'Header') {
return /* return component to be render here */
}
return null;
};export const handler = (event, context, callback) => {
hypernova(event, { getComponent }, callback);
};```