Jekyll One
  • Home
  • Previous
  • Next

2022 February, 10

  • FAQ

This is part 1 in a 1-part series:

  • 2022-02-10 · Part 1 · Jekyll FAQ
Common questions

Welcome to the FAQ page on Jekyll, a popular Static Site Generator (SSG). Many questions about Jekyll are found on the Internet and many more answers. On this page, some comprehensive answers are found for all people using the J1 Theme or having plans to do so.

Welcome to the FAQ page on Jekyll, a popular Static Site Generator (SSG). Many questions about Jekyll are found on the Internet and many more answers. On this page, some comprehensive answers are found for all people using the J1 Theme or having plans to do so.

What is a Static Site Generator?

Static website generators (SSGs) are programs that create HTML pages of a website from text-based template files or already prepared HTML sources. A SSG represent an alternative to a database-based system (CMS) such as WordPress. In content management systems, the content of a website is not managed in simple text files but stored in (relational) databases such as MySQL.

A typical CMS-driven website works by building each and every page dynamically. That means fetching the content from a database to pass them over to a template system (engine) to load the page content, adding the required structure information (e.g., CSS styles) and Javascript components if needed. This means every page is assembled on demand.

Accessing scheme for a CMS (dynamic web)
Accessing scheme for a CMS (dynamic web)

Web Browser

Web Server

Rendering Engine (e.g. PHP-based)

Database (e.g. MySQL, Postgres)

Static content (Images, Videos, JS- and CSS files) and Caches

A Static Site Generator takes a different approach and generates all the pages of the website upfront. That does not necessarily mean that a static website is always built from scratch. Modern generators support a so-called incremental build, as does. When there are changes detected to the content, only selected pages will rebuild.

Accessing scheme for a static web
Accessing scheme for a static web

Web Browser

Web Server

Server-side rendered (prepared) static content

In the case of blogs, documentation sites, or company websites, CMS and website builders are used for this, but static site generators have distinct advantages over a typically much more complex content management solution:

Speed

Websites created with a static website generator are characterized by excellent user speed. Files are processed when the page is created and not when the user views the page.

Version Control

Although the content of dynamic web projects is stored separately from the code in databases, a static website usually resides in simple text files that are fairly easy to maintain. Structurally, the content elements do not differ from other parts of the code base, so version management is set up without any problems.

Security

The advantage of websites built with static website builders is that they offer little potential for attack, unlike, for example, content management systems like WordPress, which are vulnerable to security vulnerabilities and need to be updated regularly. The risk potential is limited to the one-off access by the customer when accessing the site. Since this is usually not about more than the delivery of structured HTML pages, the probability of unwanted access is minimal.

Easy Maintenance

The number of components required for SSGs is comparatively small, but these are only relevant during development. While other solutions for live operation require various modules, databases, libraries, frameworks, and packages and have to be updated regularly, static pages are only tied to a functioning web server.

Find more to know:
J1 Theme at Jamstack Club
Popular SSGs and Themes at Jamstack Club
Popular SSGs and Themes at Jekyll Themes

What is Jekyll?

Jekyll is a popular Static Site Generator (SSG). As the name SSG implies, the generator component creates websites, but Jekyll is not a content management system (CMS) like WordPress. A static site generator is a perfect toolset to create and manage personal, project, or documentation sites because they do not rapidly change their content.

The generator concept dispenses with the convenience of a website editing system using centralized stored content in databases, in favor of editing simple files with the help of text editors. SSGs like Jekyll read the code of a content page from simple text files that contain rendering information already.

The makers of Jekyll describe it this way:

Think of it like a file-based CMS, without all the complexity. Jekyll takes your content, renders Markdown and Liquid templates, and spits out a complete, static website ready to be served by Apache, Nginx or another web server.

— The Jekyll Project

An SSG creates websites based on static content sources and generates web pages that a web server can directly deliver. A CMS creates dynamic content pages that require a web server and a rendering system to present web pages to the users. The outcome of an SSG like Jekyll and a CMS like WordPress may be quite the same, but the required software and infrastructure are very different in terms of complexity.

Find more to know:
The Philosophy of Jekyll

How to install Jekyll?

To install and run Jekyll, the dynamic programming language Ruby is required. Jekyll is a Ruby Gem that is supported on all current Windows, Linux and MacOS systems.

Run the command gem below in a terminal to install Jekyll:

gem install jekyll
Find more at RubyGems to learn what Ruby Gems are and how to use and manage them.
The builder engine Jekyll is supported by all current Ruby versions v2.7 or higher. To achive the best performance for building websites, the most recennt version V3 of Ruby is recommended.

The Ruby Gem of Jekyll contains a commandline interface (CLI) and a library system to extentend and customize the builder engine.

Find more to know:
Install Jekyll
Ruby 101
Jekyll 101

How to use Jekyll?

To use Jekyll, it is needed to learn the basics of the static websites development. The builder engine is a commandline interface (CLI) and no Graphical User Interface (GUI) or Web Interface (UI) managed by a web browser is provided.

All websites created by Jekyll are based on Themes, a template system to ease the creation process of web pages, design, styles, navigation elements and more. For a wide range of website types, the J1 Theme accessible at the Jamstack Club can be used. Check the preview function and, if the Jekyll Theme meet your needs, you can create a example web from here: Rocketstart - Create A Internet Site In Minutes Start learning the development of static webs using Jekyll the easy way!

Find more to know:
Jekyll 101
Jekyll in a Day

Is Jekyll still used?

The latest version of Jekyll v4.3.1 is issued in October 2022 and version v4.4.0 is being prepared for 2023. The next version of Jeykyll V5 is under construction and a tentative roadmap is discussed at Github: Jekyll v5 Roadmap

Find more to know:
Jekyll News