Skip to content

Commit

Permalink
fix: add support for nodejs20 for Google (#520)
Browse files Browse the repository at this point in the history
* Add node20 runtime support to google

* doc: Add Google runtime support in README

---------

Co-authored-by: Youssef Farhoun <[email protected]>
  • Loading branch information
FarhounYoussef and Youssef Farhoun authored Jan 24, 2024
1 parent 6994ff4 commit 02fcd8c
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,18 @@ This plugin will automatically set the esbuild `target` for the following suppor
| `nodejs14.x` | `node14` |
| `nodejs12.x` | `node12` |

### Google

This plugin is compatible with the [serverless-google-cloudfunctions](https://github.com/serverless/serverless-google-cloudfunctions) plugin, and will set the runtimes accordingly.

| Runtime | Target |
| ------------ | -------- |
| `nodejs20` | `node20` |
| `nodejs18` | `node18` |
| `nodejs16` | `node16` |
| `nodejs14` | `node14` |
| `nodejs12` | `node12` |

### Azure

This plugin is compatible with the [serverless-azure-functions](https://github.com/serverless/serverless-azure-functions) plugin, and will set the runtimes accordingly.
Expand Down
3 changes: 2 additions & 1 deletion src/helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ export type AwsNodeMatcher = AwsNodeProviderRuntimeMatcher<12 | 14 | 16 | 18 | 2

export type AzureNodeMatcher = AzureNodeProviderRuntimeMatcher<12 | 14 | 16 | 18>;

export type GoogleNodeMatcher = GoogleNodeProviderRuntimeMatcher<12 | 14 | 16 | 18>;
export type GoogleNodeMatcher = GoogleNodeProviderRuntimeMatcher<12 | 14 | 16 | 18 | 20>;

export type ScalewayNodeMatcher = ScalewayNodeProviderRuntimeMatcher<12 | 14 | 16 | 18 | 20>;

Expand Down Expand Up @@ -266,6 +266,7 @@ const azureNodeMatcher: AzureNodeMatcher = {
};

const googleNodeMatcher: GoogleNodeMatcher = {
nodejs20: 'node20',
nodejs18: 'node18',
nodejs16: 'node16',
nodejs14: 'node14',
Expand Down

0 comments on commit 02fcd8c

Please sign in to comment.