An Interest In:
Web News this Week
- September 10, 2024
- September 9, 2024
- September 8, 2024
- September 7, 2024
- September 6, 2024
- September 5, 2024
- September 4, 2024
Do you have your own Gatsby site? Let's brainstorm a dev.to cross-poster
So, like all good things, the idea for this post comes from a tweet:
Tierney @NodeConfCo@bitandbang@irreverentmike @amber1ey @CEO_Noor @gatsbyjs @ThePracticalDev Now that there's a @ThePracticalDev API... has anyone built a Gatsby plugin or something that automatically posts new posts?03:14 AM - 19 Jun 2019
This is something I've been ruminating on for a bit. I've even tried to build it - a few rtimes! I keep starting in on the work and getting lost in the millions of directions I could take it.
Here's what I'd like: When I publish a new post to my gatsby site, I'd like for that post to appear here on dev.to automatically.
It should:
- recreate my post verbatim, from its original markdown source
- use the
canonical_url
frontmatter field to make sure I retain SEO goodness on my post - happen without my intervention
- be agnostic of where my posts are coming from. I use takeshape.io as a headless CMS for my site, so my individual posts aren't in source control
- only take posts from my
master
branch, since I use feature branches for draft posts from time to time - use the dev.to API, of course
Nice to have:
- maybe posts should be set to
published: false
at first, so I can preview/review/update them as needed for dev.to?
Possible approaches for this:
- Tap into GitHub's webhooks somehow, and fire off a post here
- Come from a job kicked off after CI, maybe? I use CircleCI, but would like this feature to be fairly implementation agnostic.
- Use a GitHub App?
- or a GitHub Action?
- Perhaps just a lamba function deployed to AWS or Netlify Functions.
So - here's where I ask for your help. Surely there's a simple approach here I haven't thought of, or maybe it's a matter of collecting a few scenarios and building something based on 80/20.
What else am I missing here? I'd love your help. What use cases would you have for a crossposter from your gatsby site? How would you implement it? How can we help each other?
Original Link: https://dev.to/irreverentmike/do-you-have-your-own-gatsby-site-let-s-brainstorm-a-dev-to-cross-poster-1g79
Dev To
An online community for sharing and discovering great ideas, having debates, and making friendsMore About this Source Visit Dev To