DEV Community

Katie
Katie

Posted on • Originally published at katiekodes.com on

A starter for Netlify Functions with 11ty

I'm trying to set up a login-protected web site for my annual holiday letter to friends and family. Although I'm playing with Auth0 since Netlify Identity doesn't yet support magic links, I'm pretty sure after reading "Manage Subscriptions and Protect Content With Stripe" that I'll need to build a Netlify Function.

I spent 20 minutes just getting a development environment up and running -- 20 minutes I'd rather save in the future.

This particular "site" uses 11ty because I have it globally installed in my computer's NPM and it's what Jason's tutorial uses. At the moment, though, 11ty is just a way of getting an index.html live so I can feel confident my site is live.

Truly of interest to me right now is the content of the functions folder. That's where my attention is headed next.

Without further ado, here's my starter code for Netlify Functions (with a side of 11ty).

Discussion (0)