https://github.com/tkdn/work-netlify-functions
https://github.com/tkdn/work-netlify-functions
Last synced: 9 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/tkdn/work-netlify-functions
- Owner: tkdn
- Created: 2018-04-06T22:23:50.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-05-13T14:31:50.000Z (about 8 years ago)
- Last Synced: 2025-06-26T16:08:55.144Z (about 1 year ago)
- Language: JavaScript
- Size: 72.3 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Netlify Functions example
Hi there! This is my playground repo to test out [Netlify’s Lambda Functions](https://www.netlify.com/docs/functions). You can see a live
demo of the examples at https://imorente-functions-example.netlify.com.
To run the examples locally, here’s what you’ll need:
## System Requirements
* [git](https://git-scm.com)
* [NodeJS](nodejs.org) 8 or greater
* [yarn](yarnpkg.com)
## Setup
```
git clone git@github.com:imorente/netlify-functions-example.git
cd netlify-functions-example
yarn
```
## Running the examples
```
yarn start
```
This will start the client server on http://localhost:8080, and the netlify-lambda server on http://localhost:9000.
[netlify-lambda](https://github.com/netlify/netlify-lambda) isn’t required to deploy Lambda functions to Netlify, but it offers some handy features out of the box that make it quicker to get started, like the local dev server and nice defaults for transpiling and bundling functions in production.
The client server is configured to proxy `/.netlify` requests to the Lambda server (see [webpack.config.js](webpack.config.js)). This is the same behavior the site has when it’s deployed to Netlify.