The Great Gatsby

A few months ago I started to hear all of this buzz about something new - Gatsby. Don't get me wrong, I love The Great Gatsby and Leonardo Dicaprio, but when I started to hear talk about "Gatsby" thrown around with so much affection, I was genuinely confused. It turns out, however, that all of the talk wasn't about Leonardo Dicaprio (I know, I was bummed too) but was about a new technolgy that focused on giving developers the tools to create websites at an increasingly fast pace.

Gatsby is static site generator that relies heavily on React and GraphQL to get you up and running -- and it helps you get there FAST. Having a background in React, I decided to check out Gatsby primariy to get a better understand of how GraphQL works and why it should be used. I followed along on some of the tutorials on their site - their docs are incredible and I will never stop saying that enough - and then took to my keyboard to build this site using Gatsby.

Gatsby is great at separating out static content from data-dependent content. Static pages can be made up of a simple react component - I often use a stateless functional component when I'm not relying on incoming data; but, Gatsby also makes it incredibly simple (once familiar with the platform) to wrap your React components in GraphQL queries and mutations to pull in or update the data that that specific component relies on.

Here are a few of the top reasons I use gatsby for simple progressive web applications:

  1. Hot Reloading Content - UI changes appear in your local browser on a change; this comes with Gatsby, no plugins needed
  2. Built with the UI in mind - based on the fact that Gatsby is rooted in React; it creates a declarative UI and makes it easier to debug since props are passed down in a hierarchical manner (if props are passed down instead of using a GraphQL Query in the component to fetch the information needed)
  3. One way data flow - data flows from top down 🙏

This post scratches the surface on Gatsby, so if you're curious, you should head on over to their site and play around with it for yourself - I can't say enough about how amazing their docs are! https://www.gatsbyjs.org/

-A ✨