Content
asimov.js treats content as text files on disk, parsed into a key/value object and a body. Pages are stored under content/, and the path on disk becomes the URL.
content/ home.txt -> / docs.txt -> /docs blog/ first-post.txt -> /blog/first-postFile format
Each .txt file is split into a header and a body by the first line that contains ---. The header is parsed as a tiny key/value language (one key per line, key: value); the body is what you reference as {{text}} in templates.
title: asimov.jstemplate: hometags: framework, nodejs, static-site---
a better toolkit for buildingawesome websites and appsAny key in the header is available to your template by the same name. So {{title}} resolves to “asimov.js”, and {{tags}} is available too. Reserved keys are:
template— which.tmplfile to render with. Defaults topage.path— override the URL for this page.language— tag a page for use with the multi-language plugin.
Globals
Files in site/data/ are loaded once at startup and merged into every page’s context. site/data/global.txt is the conventional place to put the site title, author and other shared values:
site_title: asimov.jsauthor: Adam Renklintyear: 2014In any template, you can now use {{site_title}} without redeclaring it.
Watch & rebuild
In development, asimov-static watches content/, site/templates/, and site/styles/. Any change re-runs the affected processors and the server reloads, so your edits show up immediately.