Skip to content

docs: add general requirements into main component and remove v3 folder #437

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

Merged
merged 1 commit into from
Jun 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 30 additions & 20 deletions docs/pages/inner_workings/components/overview.mdx
Original file line number Diff line number Diff line change
@@ -1,20 +1,28 @@
import { Callout } from 'nextra/components'
import { Callout } from 'nextra/components';

<Callout>
This documentation is still a work in progress. Some parts might be missing or incomplete.

This is also mostly for advanced use cases (Overriding some default, provide support for another Cloud provider, creating your own IAC component ...), most people won't need to use this.
This is also mostly for advanced use cases (Overriding some default, provide support for another Cloud provider, creating your own IAC component ...), most people won't need to use this.

</Callout>

## General

- For the node runtime, you need at least Node 18.
- For the edge runtime, you can use both Node 18+ or cloudflare workers with `node_compat` flag enabled (Cloudflare workers support is experimental)
- Open-next doesn't work well on Windows. We recommend using WSL2 or a Linux VM.

## Backends

Every backend is a separate module. The following backends are available:
- Servers (Node or Edge runtime)
- Middleware (If manually set to external)
- Image Optimization
- Revalidation
- Warmer
- Initializer

- Servers (Node or Edge runtime)
- Middleware (If manually set to external)
- Image Optimization
- Revalidation
- Warmer
- Initializer

All these backends can be overrided to fit your needs. They share some common ground for the configuration and the way they are used.

Expand Down Expand Up @@ -56,10 +64,11 @@ export type Wrapper<
The `handler` is the original handler that is being wrapped. The `converter` is the converter that is being used to convert the event and the result.

Here is a list of the provided wrappers:
- `aws-lambda` - The default AWS Lambda wrapper - It is the default wrapper
- `aws-lambda-streaming` - The AWS Lambda wrapper with streaming support
- `node` - The Node wrapper - Create a node server, not suitable for serverless
- `cloudflare` - The Cloudflare wrapper - For Cloudflare Worker

- `aws-lambda` - The default AWS Lambda wrapper - It is the default wrapper
- `aws-lambda-streaming` - The AWS Lambda wrapper with streaming support
- `node` - The Node wrapper - Create a node server, not suitable for serverless
- `cloudflare` - The Cloudflare wrapper - For Cloudflare Worker

##### Aws Lambda streaming

Expand All @@ -84,11 +93,12 @@ export type Converter<
The `convertFrom` method is used to convert the event to the internal event used by the backend internal handler. The `convertTo` method is used to convert the result to the expected result.
`convertTo` can usually be ignored when using streaming as the result is being streamed directly.

Here is a list of the provided converters:
- `aws-apigw-v2` - The default AWS API Gateway v2 converter - It is the default converter
- `aws-apigw-v1` - The AWS API Gateway v1 converter
- `aws-cloudfront` - The AWS CloudFront converter - Used for lambda@edge
- `edge` - The Edge converter - Converts from `Request` and to `Response`
- `node` - The Node converter - Converts from `IncomingMessage` and to `ServerResponse`
- `sqs-revalidate` - The SQS Revalidate converter - Used by default for the revalidation backend
- `dummy` - The Dummy converter - Does nothing
Here is a list of the provided converters:

- `aws-apigw-v2` - The default AWS API Gateway v2 converter - It is the default converter
- `aws-apigw-v1` - The AWS API Gateway v1 converter
- `aws-cloudfront` - The AWS CloudFront converter - Used for lambda@edge
- `edge` - The Edge converter - Converts from `Request` and to `Response`
- `node` - The Node converter - Converts from `IncomingMessage` and to `ServerResponse`
- `sqs-revalidate` - The SQS Revalidate converter - Used by default for the revalidation backend
- `dummy` - The Dummy converter - Does nothing
7 changes: 0 additions & 7 deletions docs/pages/v3/_meta.json

This file was deleted.

69 changes: 0 additions & 69 deletions docs/pages/v3/config.mdx

This file was deleted.

67 changes: 0 additions & 67 deletions docs/pages/v3/index.mdx

This file was deleted.

74 changes: 0 additions & 74 deletions docs/pages/v3/override.mdx

This file was deleted.

Loading
Loading