MDRX

Blogged Up

March 9, 2019

Hello, World! Here’s my blog about work, life, tech, games, and anything else I want to write about. As my inaugural post, it’s only fitting that I blog about how I set up this blog.

To start off, my name is Mike and I’m a generalist engineer with a serious interest in Front-end development these days so I was naturally inclined to play around with some shiny new things. React is my jam right now, and the recently released Hooks put the spice back into this aging 5-year old JavaScript framework.

I’ve been working on some internal tools for my employers and have found that serverless webapps are great: you generate your app, push it to S3, check a box for static website hosting, and boom - the easiest website you never served. Most importantly, in the words of my colleague whom I will claim is a security expert, this method is “nearly unhackable (sic)“.

Okay, so an S3-deployed website… written how? I already said React. Do I want to build it from scratch? Blogs can be simple or they can be complex with a lot of content to manage. How about somewhere in between? All the Front-end pros I’ve been following on Twitter have been raving about Gatsby.js. Lo and behold, even the React website itself it built with Gatsby.

I dig into Gatsby a bit… React-focused? Check. Pre-made starter blog recipe? Check. GraphQL (👎 REST)? Check. Content kept local on-disk as Markdown files? Check! I’m going over the README and at the bottom there’s a little button that says “Deploy to netlify”.

Wow, Netlify is awesome - and apparently others think so, too. It’s optimized to just automatically hook into my blog’s github repo, regenerate the static website every time I push commits to the remote, and then host it for free (for my purposes).

Wasn’t all super smooth, though. I got stuck for a bit when I added a global stylesheet by recommendation of the Gatsby docs, and just could not get the new CSS into the build. Fortunately I wasn’t alone and I found the issue had already been reported. I lost an extra half hour due to Yarn, though. Shiny new things indeed.


Mike Lewis

I'm currently a Software Engineering Manager (with a very generalist engineering background across embedded systems, robotics, and Frontend/UI) and I most recently worked at Cruise in the SF Bay Area. Welcome to my blog, where I write about tech, development, having a family, and other interests. You can follow me on X. Or check out my LinkedIn.

© 2024, Mike Lewis