-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bump platformVersion to 2023.2 (#19)
* Bump to platformVersion 2023.2 * Bump node runtime to 18 * Use async/await * Remove runtime and version * Update example functions to use async --------- Co-authored-by: Camden Phalen <[email protected]> Co-authored-by: Hugh McDonald <[email protected]>
- Loading branch information
1 parent
ff115c3
commit 4e5dd8e
Showing
8 changed files
with
12 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,7 @@ | ||
exports.main = (context = {}, sendResponse) => { | ||
exports.main = async (context = {}) => { | ||
const { text } = context.parameters; | ||
|
||
const response = `This is coming from a serverless function! You entered: ${text}`; | ||
|
||
try { | ||
sendResponse(response); | ||
} catch (error) { | ||
sendResponse(error); | ||
} | ||
return response; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
{ | ||
"runtime": "nodejs16.x", | ||
"version": "1.0", | ||
"appFunctions": { | ||
"myFunc": { | ||
"file": "example-function.js", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"name": "Get Started Project", | ||
"srcDir": "src", | ||
"platformVersion": "2023.1" | ||
"platformVersion": "2023.2" | ||
} |
8 changes: 2 additions & 6 deletions
8
projects/getting-started-template/src/app/app.functions/example-function.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,7 @@ | ||
exports.main = (context = {}, sendResponse) => { | ||
exports.main = async (context = {}) => { | ||
const { text } = context.parameters; | ||
|
||
const response = `This is coming from a serverless function! You entered: ${text}`; | ||
|
||
try { | ||
sendResponse(response); | ||
} catch (error) { | ||
sendResponse(error); | ||
} | ||
return response; | ||
}; |
2 changes: 0 additions & 2 deletions
2
projects/getting-started-template/src/app/app.functions/serverless.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
{ | ||
"runtime": "nodejs16.x", | ||
"version": "1.0", | ||
"appFunctions": { | ||
"myFunc": { | ||
"file": "example-function.js", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"name": "Empty Project", | ||
"srcDir": "src", | ||
"platformVersion": "2023.1" | ||
"platformVersion": "2023.2" | ||
} |