Front-end Design Conf Share Pear
Share Pear is a platform built with Astro, Netlify On-Demand Builders, and Edge Functions to consume markdown content and generate public HTML pages from that content!
npm install && npm run dev
localhost:3000/blog/whatever
You'll have to hard-code in some URI-encoded markdown in the url, for example
localhost:3000/blog/whatever/{MARKDOWN}
, to see how a blog looks.
public/
src/layouts/Layout.astro
src/index.astro
, src/404.astro
, andsrc/blog/[slug].astro
allowedUrlsRegex
in netlify/edge-functions/headers.js
withhttps://fedc.netlify.app/blog/[SOMETHING]
with a GET requestmarkdown: "blah"
whereblah
is the blog content. This request publishes your blog post at thehttps://fedc.netlify.app/blog/[SOMETHING]
url for 30 days.