A static site generator (SSG) is an application that converts simple text files (with minimal markup) to static sites using predifend templates (Themes). They provide a middle ground between fully fledged Content Managment Systems (like wordpress or drupal) and statically build sites.
Pros
- No server-side infrastructure except a simple http server (no database, no server-side application).
- Simple deployment procedure (just copy the generated files).
- Every deployment is a full deployment (no differences between local and remote site)
- Easily to track content and theme via source code versioning system
- Content consistency (every page looks the same due to template usage)
Cons
- The application is required in order to alter content (ie. cannot publish frpm mobile)
- No advanced content management or authorization model
- There is a learning curve for doing more complex tasks (but this is true for every other option)
Use case
SSGs are a fitting option for personal or small teams, blog-style sites where any commenting is either disabled or off-loaded to another tool (ie facebook comments) - If the team member are familiar with text editing, markdown and git (like developers are) even better.
Operation & Setup
The typical steps to setup an SSG are:
- Download SSG binaries or script
- Create a new folder (project)
- Download a theme
- Configure site parametes (title, url, theme, etc)
- Create content (simple ascii files, using markdown)
- Build static files
- Deploy static files
Which one?
There are multiple SSGs to select from, but the 3 most used are:
- Jekyll is the most used (partailly due to being used by github pages), but setting up RoR on a windows machine could be intimidating..
- Hugo is build in "Go" but ships as a single executable and is a nice option
- Hexo is build in node.
My personal preference is Hugo
Top comments (3)
No, not yet at least