File: data.md

package info (click to toggle)
staticsite 2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 14,648 kB
  • sloc: javascript: 33,722; python: 9,851; makefile: 46; sh: 4
file content (20 lines) | stat: -rw-r--r-- 667 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# data: Handle datasets in content directories.

## Page types

* [data](../pages/data.md): Data files

## Documentation

This allows storing pure-data datasets in JSON, Yaml, or Toml format in
the contents directory, access it from pages, and render it using Jinja2
templates.

Each dataset needs, at its toplevel, to be a dict with a ``type`` element,
and the dataset will be rendered using the ``data-{{type}}.html`` template.

Other front-matter attributes like ``date``, ``title``, ``aliases``, and
taxonomy names are handled as with other pages. The rest of the dictionary
is ignored and can contain any data one wants.

[Back to reference index](../README.md)