Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
June 22, 2019 08:40 pm GMT

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:

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:

  1. Tap into GitHub's webhooks somehow, and fire off a post here
  2. Come from a job kicked off after CI, maybe? I use CircleCI, but would like this feature to be fairly implementation agnostic.
  3. Use a GitHub App?
  4. or a GitHub Action?
  5. 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

Share this article:    Share on Facebook
View Full Article

Dev To

An online community for sharing and discovering great ideas, having debates, and making friends

More About this Source Visit Dev To