shizuka
shizuka  /  docs

Creating Sites

Structure a Shizuka source directory.

A Shizuka site is a directory with a config file and some content:

Diagram showing a Shizuka source site folder and the generated dist folder output.

Source site folder and generated dist/ output.

File Structure

PathPurpose
content/Source pages. Markdown pages are converted to HTML and then rendered through a template.
data/Optional structured data manifests registered as query tables.
templates/Go template files. HTML layouts live under templates/html/; markdown components live under templates/md/.
static/Copied to the output as-is: CSS, images, JavaScript, fonts, and other static files.
dist/The default build output folder.

Output Structure

Shizuka outputs pretty URLs by writing index.html files into directories. Files named index.* are treated treated as belonging to their parent directory, whereas other files will create their own directory + index.html file, depending on their name.

For example:

SourceOutput
content/index.mddist/index.html
content/about.mddist/about/index.html
content/posts/hello.mddist/posts/hello/index.html
content/posts/index.mddist/posts/index.html

Content File Types

ExtensionBehavior
*.mdMarkdown body, optional frontmatter.
*.htmlRaw HTML body, optional frontmatter.
*.toml, *.yaml, *.yml, *.json, *.jsoncStructured page objects. They must contain template and body; set body_markdown = true to render body as Markdown.

All other filetypes under content/ are ignored. Put CSS, images, JavaScript, fonts, and other static files under static/.

Data Files

If a data/ directory exists, Shizuka loads *.toml, *.yaml, *.yml, *.json, and *.jsonc files as data manifests. Each manifest can define one or more query tables:

{
  "tables": {
    "products": {
      "name": "shop_products",
      "rows": [
        { "id": "a", "title": "Alpha" },
        { "id": "b", "title": "Beta" }
      ]
    }
  }
}

name is the public table identifier used in template queries. rows may be an array of objects or a keyed object whose keys are added as a key column.