Skip to content

4.6.2

Compare
Choose a tag to compare
@Inqnuam Inqnuam released this 14 Aug 04:19
· 34 commits to main since this release
  • updated esbuild
    with 0.19.0 esbuild shipped a bug which changed the behaviour of tsconfig baseURL
  • updated body-parser
    now Router body-parser plugin parses form-urlencoded requests correctly out of box
  • added a quick-start project example
    with the help of npx and degit you can now start a new project whitin seconds
  • introduce LOCAL label to remove chunk of code when deploying
    It's now possible to execute a chunk of code only when developing locally with LOCAL label statement. Previously it was possible by checking IS_LOCAL value from process.env or with some additional esbuild configuration, example:
export const handler = async (event)=> {

 if (process.env.IS_LOCAL == "true") {
   console.log("do something locally")
 }

 return {
  statusCode: 200,
  body: "Hello World!"
 }

}

now you can also achieve the same thing with a more elegant and less error prone with LOCAL label solution:

export const handler = async (event)=> {

 LOCAL: {
   console.log("do something locally")
 }

 return {
  statusCode: 200,
  body: "Hello World!"
 }

}