cli
cli copied to clipboard
Local Functions Not Working with Node 17+
Describe the bug
When running netlify dev, local functions are not accessible on port 8888 when using Node.js version 17.
To Reproduce
Steps to reproduce the behavior:
- Create a new hello world function inside of a functions directory
- Install Node.js 17+
- Run
netlify devin the project and try to access in the browser athttp://localhost:8888/.netlify/functions/helloWorld
Expected behavior
Should return back hello world from the browser.
Check out #3617. The issue has been reported for different frameworks. Had the same issue after updating to Node.js 17+. Going back to an older version of Node solved the issue for now.