We can keep APIs and UIs in sync by having the APIs be part of the same repo. Serverless functions are handy for that.
To work on this project locally and explore the code:
# clone the code repository
git clone [email protected]:philhawksworth/example-api-and-ui.git
# move into the project directory
cd example-api-and-ui
# install the dependencies
npm install
# install the Netlify CLI for local serverless functions
npm install -g netlify-cli
# run the build with netlify dev
# and find the local site at http://localhost:8888
netlify dev
To quickly experiment with this example, you can click the button below. Clicking the button will clone this site repo, setup a new site on Netlify and deploy the site complete with Netlify's CI/CD pipeline configured and operational.