Edit On GitHub
I recently added a button to my blog, and subsequently my posts on
DEV.to [1]. It’s the best thing that I have done
for it in a while. It makes it so easy to do quick edits.
finding errors # [2]
I refer back to my old posts quite a bit, sometimes I find errors in them.
Honestly most of the time its too much effort to load up my editor make the
change and git add and git commit. It’s not much, but when I am referring
to my own post generally I am just trying to get something done and don’t have
time for that.
The slug # [3]
The slug that I am getting from gatsby is formatted as /blog/this-post/.
Note the trailing slash and missing file extension, thats where the
${slug.slice(0, -1)}.md comes in.
The Full Link # [4]
GitHub makes it super easy to form a URL that puts you right into edit mode on
the exact post you are looking for. This is format for the URL… you can
always figure it out easily by clicking edit on one.
https://github.com/<user>/<repo>/edit/<branch>/<filepath>
The...