DEV Community

Derek Hopper
Derek Hopper

Posted on • Updated on

How have you used static site generators to creatively simplify things?

If what you normally use to build applications is a framework like Ruby on Rails, it becomes easy to use that tool for everything. Simple is often better. Sometimes using a static site generator is the better long-term option.

Do you use static site generators like jekyll or gatsbyjs to do neat things? What use cases have you found best served by static site generators?

Oldest comments (2)

Collapse
 
derekjhopper profile image
Derek Hopper

I like using concepts from static site generators when thinking about content on the page. For example, we have a page that uses a YAML file to fill much of its content. This helps with a few things:

  • People with no knowledge of HTML/CSS can update content.
  • Your content is structured in a file all by itself.
  • Developers can focus on higher value tasks instead of filling in content.
  • Updating content doesn't require you to search for the HTML.
  • It keeps your HTML/CSS a little bit cleaner.
Collapse
 
gtb3nw profile image
GTB3NW

The most creative use of a static site generator is a static API. It doesn't require a database and doesn't require PHP. It may use more disk space but ahh well, what's disk space compared to CPU cycles and memory?

I'm really liking the way things are going with static site generators. I do hope they get more popular. I even said to a client who was having troubles with their WordPress being hacked that they need to keep on top of updates. They asked if there's any way around it. My response "Don't use code". They were intrigued by the idea of a static site generator, but alas they likely don't have the skill set required to get started and it wasn't in my companies interest to recommend a competitor product to manage that.