Steno turns Markdown files into static HTML, adds frontmatter and theme support, and ships with a small CLI plus a live-reloading dev server.
Steno is designed around a simple content pipeline:
- Read Markdown files from
content/ - Parse YAML or TOML frontmatter
- Convert Markdown to HTML with
marked - Optionally render the HTML through a Scribe-based theme
- Write the generated pages to
dist/ - Copy theme assets into
dist/assets/
That makes it a good fit for blogs, documentation sites, small marketing sites, and theme-driven static websites.
- Markdown pages rendered to HTML with
marked - YAML and TOML config loading
- Frontmatter support with
---(YAML) and+++(TOML) - Theme layouts, components, and static assets
- Scribe templates for layouts and components
- Live-reloading dev server on
http://localhost:8000 - CLI support for
build,dev,--config, and--help - Root test harness with
deno task test
The package exports mod.ts, so you can import it directly in a Deno project:
import { Steno } from "@steno/steno";
new Steno();For local development inside this repo, the current workflow is:
deno task dev
deno task test
deno run -A ./mod.ts buildCreate the default config file at content/.steno/config.yml:
title: My site
description: A Steno site
author: Your Name
contentDir: content
output: dist
custom:
shortUrls: true
theme: "./test/test-theme"
themeConfig:
author: "Your Name"Add a page at content/index.md:
---
title: Home
layout: layout
---
# Hello
Welcome to Steno.Then build the site:
deno run -A ./mod.ts build --config content/.steno/config.ymlOr start the dev server with live reload:
deno run -A ./mod.ts dev --config content/.steno/config.ymlSteno’s CLI is implemented in src/cli.ts and used by mod.ts.
build— generate the site intodist/(default)dev— start the dev server with file watching--help— print CLI usage
-c, --config <path>— path to the site config file
deno run -A ./mod.ts
deno run -A ./mod.ts build
deno run -A ./mod.ts dev
deno run -A ./mod.ts build --config content/.steno/config.yml
deno run -A ./mod.ts --helpSteno loads config from YAML or TOML. The default path is content/.steno/config.yml.
Supported top-level fields used by the current runtime include:
titledescriptionauthorheadcontentDiroutputcustom.shortUrlscustom.themecustom.themeConfig
Example:
title: My site
description: A site built with Steno
author: Your Name
contentDir: content
output: dist
head:
- name: icon
content: /favicon.ico
custom:
shortUrls: true
theme: "./test/test-theme"
themeConfig:
author: "Your Name"shortUrls: truewrites pages likeabout/index.htmlinstead ofabout.html.steno/is reserved for internal config files- only
.mdfiles are processed during builds
Themes are loaded from custom.theme and can be either:
- a local theme directory containing
theme.yamlortheme.yml - a module import such as
jsr:,npm:,file:, orhttps:
Directory-based themes conventionally use:
layouts/*.scrfor layoutscomponents/*.scrfor reusable componentsassets/**for static files copied todist/assets/
Example theme.yaml:
name: "Steno Minimalist"
version: "1.0.0"
components:
header: "components/header.scr"
footer: "components/footer.scr"
defaultConfig:
author: "Steno Creator"Example theme structure:
test/test-theme/
├── theme.yaml
├── assets/
│ └── style.css
├── components/
│ ├── footer.scr
│ └── header.scr
└── layouts/
├── layout.scr
└── post.scr
Steno themes are rendered with Scribe, not Liquid.
Common patterns:
{#if title}
<Header />
{/if}
{@html content}
{ tags | join: ", " }
{#each tags as tag}
<span>{tag}</span>
{/each}
Layouts receive a context object containing:
site— the site configtheme— theme metadata plus merged theme configcontent— rendered Markdown HTML- frontmatter fields such as
title,layout,date,tags, andauthor
The default layout name is layout when frontmatter does not specify one.
The repo is structured so that the root package points at mod.ts, while the sandbox app lives under test/.
deno task devdelegates totest/deno task testruns the roottest.tsharnesscd test && deno task buildbuilds the sandbox site directly
Useful commands:
deno check
deno lint
deno task test
cd test && deno task buildThe main exports from mod.ts are:
StenoThemerenderfiltersStenoTheme
This lets you use the package as a library or as a runnable CLI entrypoint.
The current implementation already includes:
- Markdown-to-HTML compilation
- theme loading and rendering
- asset copying
- a CLI
- live reload in dev mode
- a test suite
MIT — see LICENSE.txt.