Create Your First Serverless Function
Create a new file at /netlify/functions/hello-world.js
and put the following inside:
exports.handler = () => { return { statusCode: 200, body: 'hello world!', }; };
Save it, then run netlify dev
to test locally. Check your work by clicking the button below!