What is Yass?
Yass is an astonishingly un-opinionated static site generator. Your sites’s structure is entirely up to you: organize static assets, .html
files, .md
(Markdown) files, and .liquid
(Liquid) templates however you want under site/
. Liquid layouts and reusable templates are supported but optional.
The one opinion Yass holds is that you should decide everything. There’s zero configuration and no conventions to learn!
Getting started
Starting from a blank page isn’t fun, so yass init
spits out the source to this very site to help get you started.
$ gem install yass
$ yass init blog
Creating blog/layouts/default.html.liquid
Creating blog/layouts/splash.html.liquid
Creating blog/site/assets/highlight.min.js
Creating blog/site/assets/highlightjs-atom-one-dark.min.css
Creating blog/site/assets/main.css.liquid
Creating blog/site/helpers/index.md.liquid
Creating blog/site/index.splash.md.liquid
Creating blog/site/layouts-templates/index.md.liquid
Creating blog/templates/asset_tags.liquid
Creating blog/templates/nav.liquid
$ cd blog
site/
contains your site’s source.layouts/
contains Liquid layouts (optional).templates/
contains reusable Liquid templates (optional).
Building
Build your site into the dist/
directory with yass build
.
$ yass build
Previewing
To preview your site on your computer, simply open dist/index.html
with your browser 🤯. (This requires using relative links, but there are helpers for that.)
If you’re building for webserverless, local viewing, and using the skip_index
filter anywhere, use the --no-skip-index
option.
$ yass build --no-skip-index
The watch
command will continuously build as you make changes in site/
, layouts/
, and templates/
.
$ yass watch # --no-skip-index works here too
Interested?
Keep reading about layouts, templates, and helpers, or check out the code on Github!