---
title: "Discussion on \"How to debug Netlify serverless lambda functions using VS Code for your JAMstack app\" | Hashnode"
description: "Discussion on \"How to debug Netlify serverless lambda functions using VS Code for your JAMstack app\". The JAMstack is a modern web development architecture based on client-side JavaScript, reusable APIs, and prebuilt Markup. JAMstack applications are practically serverless. To put it more clearly, we do not maintain any server-side applications but r..."
url: "https://hashnode.com/posts/how-to-debug-netlify-serverless-lambda-functions-using-vs-code-for-your-jamstack-app/5fb0becac03b0e471014fd25"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [How to debug Netlify serverless lambda functions using VS Code for your JAMstack app](https://blog.greenroots.info/how-to-debug-netlify-serverless-lambda-functions-using-vs-code-for-your-jamstack-app?utm_source=hashnode&utm_medium=feed)

The JAMstack is a modern web development architecture based on client-side JavaScript, reusable APIs, and prebuilt Markup. JAMstack applications are practically serverless. To put it more clearly, we do not maintain any server-side applications but r...

Nov 15, 2020 · 5 min read · blog.greenroots.info  
Updated May 13, 2021  
Read the article

-   [#programming](https://hashnode.com/tag/programming)
-   [#javascript](https://hashnode.com/tag/javascript)
-   [#debugging](https://hashnode.com/tag/debugging)
-   [#vscode](https://hashnode.com/tag/vscode)
-   [#netlify](https://hashnode.com/tag/netlify)

## Written by

[Tapas Adhikary](https://hashnode.com/@atapas)

@atapas · Bangalore

  
[View profile](https://hashnode.com/@atapas)

Educator @tapaScript | Founder CreoWis & ReactPlay - Writer - YouTuber - Open Source

Co-Founder, @CreoWis | Teacher, @tapaScript | Founder, @ReactPlay | YouTuber | Writer | Human

## Responses 1

Markdown supported · ⌘↵ to post

[Michal](https://hashnode.com/@michalhudecek)

[Dec 5, 2020](https://hashnode.com/posts/how-to-debug-netlify-serverless-lambda-functions-using-vs-code-for-your-jamstack-app/5fb0becac03b0e471014fd25/comment/5fcb4d022e4db7780e483068)

Hi,

thanks for a great article. I tried to follow it but can't make it work. After some investigation it looks like the sourcemaps for lambda functions are actually not generated at all and therefore the breakpoints do not work. I can't find sourcemaps in `/lambda` folder. Am I missing any pre-requisite?

I am using `netlify-cli/2.69.1 win32-x64 node-v14.15.1`

Thanks

[Michal](https://hashnode.com/@michalhudecek)

[Dec 7, 2020](https://hashnode.com/posts/how-to-debug-netlify-serverless-lambda-functions-using-vs-code-for-your-jamstack-app/5fb0becac03b0e471014fd25/comment/5fcb4d022e4db7780e483068#reply-5fcdf3017d1d8b0b087485af)

[Tapas Adhikary](https://hashnode.com/@atapas)

I do use `netlify dev`. Yes, the functions are in `/src/lambda` and when I run `netlify dev` they are generated to `/lambda` folder. However, there are no sourcemaps in `/lambda` folder. I believe that is why I get the error about sourcemaps not found.

When I add a break point to any function in `/src/lambda` it is not triggered, because the actual JS that is being run when I call any Netlify function is in `/lambda` folder.

_Where exactly are sourcemaps for lambda functions located in your project?_

[Tapas Adhikary](https://hashnode.com/@atapas)

[Dec 7, 2020](https://hashnode.com/posts/how-to-debug-netlify-serverless-lambda-functions-using-vs-code-for-your-jamstack-app/5fb0becac03b0e471014fd25/comment/5fcb4d022e4db7780e483068#reply-5fcdfa16c5255915c49a8628)

[Michal](https://hashnode.com/@michalhudecek), hmm interesting as I do not see any of the related sourcemaps either. My `functions` folder is outside of the src though as the `src` is meant for having the UI code for me.

![image.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1607334214184/_avg92C3N.png)

I see it connects all the time and I am able to debug too..

![image.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1607334257762/DG7Grf9y1.png)

Do you want to debug it out together 😃? We can jump into a 30 mins google meet/zoom call to do that tomorrow. Let me know, I can ping you the meeting id on Twitter.

[Michal](https://hashnode.com/@michalhudecek)

[Feb 11, 2021](https://hashnode.com/posts/how-to-debug-netlify-serverless-lambda-functions-using-vs-code-for-your-jamstack-app/5fb0becac03b0e471014fd25/comment/5fcb4d022e4db7780e483068#reply-6024e35a8a18494dfcecbfb7)

[Tapas Adhikary](https://hashnode.com/@atapas) I finally made it work. I had to add lambda.config.js file and reference to it in package.json scripts. You can check the details here [github.com/netlify/netlify-lambda/issues/262](https://github.com/netlify/netlify-lambda/issues/262)
