# Every name

Every name `ssqch docs` knows, 93 of them, with its one line from where it's defined (`ssqch.d.ts`, the command line, the template functions) and the page that explains it. In a project with ssqch installed, `ssqch docs <name>` answers for the version you have.

## Commands

- `ssqch build`: Build the site (default). See [The build](https://sitesquatch.dev/docs/netlify/index.md#the-build).
- `ssqch serve`: Build, serve, watch for changes and live-reload the browser (--built serves the last build as it is). See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `ssqch new`: Create a page from a blueprint (a file in _blueprints/), with its title and date filled in. See [Starting a new page](https://sitesquatch.dev/docs/new-pages/index.md).
- `ssqch trace`: Follow a page's tracks: where it comes from, and which level of the data cascade set each value. See [Reading the build summary](https://sitesquatch.dev/docs/build-summary/index.md).
- `ssqch completions`: Print a completion script for your shell, so Tab finishes commands and options. See [Gear up: install](https://sitesquatch.dev/docs/install/index.md).
- `ssqch diff`: Compare two builds of a site: URLs added and removed, and what changed on each page. See [Has the stump moved? Comparing two builds](https://sitesquatch.dev/docs/comparing-builds/index.md).
- `ssqch footprint`: Show how much a build weighs: its files by kind, and the heaviest pages and files. See [A build's footprint](https://sitesquatch.dev/docs/footprint/index.md).
- `ssqch patrol`: Check a build for what agents and crawlers read: robots.txt, the sitemap, llms.txt, Markdown copies, headings and descriptions. See [What patrol checks](https://sitesquatch.dev/docs/patrol/index.md#what-patrol-checks).
- `ssqch init`: Create a starter site (a blog, or a docs site with --starter docs). See [The build](https://sitesquatch.dev/docs/netlify/index.md#the-build).
- `ssqch types`: Write ssqch.d.ts, the types editors use for ssqch.config.js. See [Content schemas](https://sitesquatch.dev/docs/content-schemas/index.md).
- `ssqch scout`: Scout a site built with another generator: what moving it to ssqch takes, with file and line, and what's left during a move. See [Scouting a site](https://sitesquatch.dev/docs/trailheads/index.md#scouting-a-site).
- `ssqch baseline`: Build the site in fresh copies with the clock pinned, and compare the builds: that an ssqch build repeats, or, before a move, what to compare ssqch's with. See [Reference builds](https://sitesquatch.dev/docs/comparing-builds/index.md#reference-builds).
- `ssqch capabilities`: Say what this binary supports: template languages, modules, config options and optional features. See [Scripts and coding agents](https://sitesquatch.dev/docs/agents/index.md).
- `ssqch docs`: Read the documentation for this version: a command, config option, function or topic. See [A big site's llms.txt](https://sitesquatch.dev/docs/robots/index.md#a-big-sites-llmstxt).

## Config options

- `dirs`: Folders. See [What a hook and a transform get](https://sitesquatch.dev/docs/configuring/index.md#what-a-hook-and-a-transform-get).
- `templateFormats`: File extensions to render. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `markdownEngine`: The engine that runs over `.md` files first: `"jinja"` (the default), `"edge"`, `"liquid"`, `"njk"`, `"hbs"`, `"ejs"`, or `false` for none. See [Math with KaTeX or MathJax](https://sitesquatch.dev/docs/markdown/index.md#math-with-katex-or-mathjax).
- `htmlEngine`: The engine that runs over `.html` files first. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `markdown`: Heading IDs, footnotes and the other Markdown extensions. See [Markdown](https://sitesquatch.dev/docs/markdown/index.md).
- `deepMerge`: Merge objects and concatenate arrays through the data cascade. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `leaveNoTrace`: Delete output files an earlier build wrote or copied that this one didn't (a deleted post's page, a picture `imagePlugin()` encoded that no page uses now). See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `ignore`: Globs (relative to the input folder) of files that aren't pages, like `["drafts/**", "notes/*.wip.md"]`. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `pageBundles`: Page bundles: copy the other files in a folder whose page is `index.*` (images, downloads) next to the page. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `strict`: Printing an undefined value (`{{ titel }}`) is an error, in every template language. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `jinja`: Jinja's settings for `.jinja` and `.j2` templates. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `lastModified`: `page.lastModified`: `"git"` for the last commit that changed the page's file (its modification time when it has uncommitted changes), or `"file"` for the modification time. See [Following the tracks: where a value comes from](https://sitesquatch.dev/docs/where-values-come-from/index.md).
- `dateFallback`: The date of a page with no date of its own (in its data or its file name): `"git"` for the last commit that changed its file, the same in every checkout, or `"file"` (the default) for the file's modification time, which is when the checkout wrote it. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `timeZone`: The time zone the site's own JavaScript runs in, as an IANA name (`"UTC"`, `"America/New_York"`): `Date`'s local methods and libraries like luxon and date-fns, in data files, filters, hooks and Edge templates, so a laptop and CI build the same pages. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `urls`: A page's URL when it has no `permalink`: `"folders"` (the default) writes `guide/intro.md` as `/guide/intro/` (`guide/intro/index.html`), `"html"` as `/guide/intro.html`. See [Markdown steps](https://sitesquatch.dev/docs/writing-plugins/index.md#markdown-steps).
- `layoutAliases`: Other names for layouts: `{ post: "layouts/post.njk" }` makes `layout: post` that file (where it would be `_includes/post.*`). See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `base`: The path the site is served under, when that isn't the root of its domain: `"/repo/"` for `https://you.github.io/repo/`. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `schemas`: Content schemas, by name: `{ posts: { fields: { title: "string", date: "date" } } }` checks every page tagged `posts`. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `theme`: A theme under the site: a folder (`"themes/docs"`), or a git repository pinned to a tag or a commit's full hash (`"https://github.com/you/theme#v1.2.0"`, with `#v1.2.0:folder` for a theme in a folder of its repository), fetched once and kept in `.cache/ssqch/themes/`. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `serve`: What `ssqch serve` runs besides the server. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `budgets`: Size budgets by kind of file, checked after each build: a file over its kind's budget is an `over-budget` warning, or with `fail: true` an error that fails a production build (development builds and `ssqch serve` still warn). See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `data`: Data for every template. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `filters`: Functions templates can call: `{{ slug(title) }}`. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `collections`: Custom collections, from the pages in collections. See [Tags and tag pages](https://sitesquatch.dev/docs/templates/index.md#tags-and-tag-pages).
- `transforms`: Run on every output file. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `engines`: Template engines of your own, by file extension: a function, or an object with `render` (a markdown-it instance is one: `render(source, env)` gets the page's data as `env`). See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `passthrough`: Files or folders to copy: a path, or `{ from: to }`, or an array of them. See [CSS and JavaScript](https://sitesquatch.dev/docs/css-and-javascript/index.md).
- `watch`: More paths for `ssqch serve` to watch. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `beforeBuild`: Run before each build: a function, `{ run: "command" }`, or a list of them. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `afterBuild`: Run after each build, with `written` (the pages it wrote and the files plugins made beside them). See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `plugins`: More config, from plugins. See [Writing a plugin](https://sitesquatch.dev/docs/writing-plugins/index.md).

## Template functions

- `markdown`: `markdown(text)` renders Markdown with the site's options; `markdown(text, "inline")` without the `<p>`. See [Markdown](https://sitesquatch.dev/docs/markdown/index.md).
- `toc`: `toc(page.headings)` is a table of contents (or `toc(html)`, from HTML's headings); `toc(page.headings, { from: 2, to: 4, ordered: true })` picks the levels, and `id`, `class`, `sublistClass`, `itemClass` (`{level}` is the heading's) and `linkClass` set the markup's. See [Markdown](https://sitesquatch.dev/docs/markdown/index.md).
- `navTree`: `navTree(nav, page.url)` marks a navigation tree's entries `current`, `ancestor` or `open`. See [Templates and data](https://sitesquatch.dev/docs/templates/index.md).
- `navPager`: `navPager(nav, page.url)` is `{ previous, next }` in reading order. See [Templates and data](https://sitesquatch.dev/docs/templates/index.md).
- `navBreadcrumbs`: `navBreadcrumbs(nav, page.url)` is the entries from the top down to the page. See [Templates and data](https://sitesquatch.dev/docs/templates/index.md).
- `pagesTree`: `pagesTree(collections.docs)` builds a navigation tree from pages' `nav` front matter; `pagesTree(collections.all, { root: "Feature" })` (or `pagesTree(collections.all, "Feature")`) is the tree below one key. See [A sidebar from front matter](https://sitesquatch.dev/docs/templates/index.md#a-sidebar-from-front-matter).
- `highlight`: `highlight(code, lang)` is highlighted HTML for inside a `<code>`, with `hl-*` classes. See [Markdown](https://sitesquatch.dev/docs/markdown/index.md).
- `readingTime`: `readingTime(content)` is the minutes it takes to read some HTML, at 200 words a minute. See [Templates and data](https://sitesquatch.dev/docs/templates/index.md).
- `withBase`: `withBase("/feed.xml")` puts the site's `base` in front of a URL, for places outside HTML attributes. See [Serving a site under a path](https://sitesquatch.dev/docs/deploying/index.md#serving-a-site-under-a-path).
- `absoluteUrl`: `absoluteUrl(page.url, site.url)` is a whole address: the URL against the site's, with the site's `base` in front of a URL from the root that doesn't have it yet. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `slugify`: `slugify("Pine Cone Crunch!")` is `pine-cone-crunch`: lowercase letters and digits, with a dash for each run of anything else; `slugify(title, { separator: "_" })` uses another separator, `apostrophes: "separate"` splits words at an apostrophe instead of dropping it, `ascii: true` takes accents off and spells out symbols as the slugify package does (`Sjögren & co` is `sjogren-and-co`), and `stripTags: true` drops HTML tags first. See [Templates and data](https://sitesquatch.dev/docs/templates/index.md).

## From "ssqch"

- `defineConfig`: Returns its argument. See [Configuring a site](https://sitesquatch.dev/docs/configuring/index.md).
- `markdown`: Render Markdown with the site's `markdown` options (render hooks and containers are for templates). See [Markdown](https://sitesquatch.dev/docs/markdown/index.md).
- `readData`: Read a JSON, YAML or TOML file (from the project root) into data: `readData("src/_data/sites/en.yml")`. See [JavaScript data files](https://sitesquatch.dev/docs/data-files/index.md).
- `safe`: HTML that templates print as it is, in every template language: a filter's answer that's markup, `return safe(`<b>${text}</b>`)`. See [What a filter sees](https://sitesquatch.dev/docs/configuring/index.md#what-a-filter-sees).
- `files`: The files a glob matches, from the project root and ignoring case, sorted by path, as data: `files("images/albums/v1/*.{jpg,png}")`. See [JavaScript data files](https://sitesquatch.dev/docs/data-files/index.md).
- `slugify`: The `slugify` template filter, for data files: `slugify("Taco Bake", { separator: "_" })` is `"taco_bake"`. See [Templates and data](https://sitesquatch.dev/docs/templates/index.md).
- `slugger`: A `slugify` that counts, so every slug it makes is different: the first "Misc Pictures" is `misc-pictures`, the next `misc-pictures-1`, then `misc-pictures-2`. See [JavaScript data files](https://sitesquatch.dev/docs/data-files/index.md).
- `withBase`: The `withBase` template function, for a site's own code (a data file, a filter, `computed`): a URL from the site's root with the site's `base` in front, `withBase("/provisions/moss-mix/")` is `"/repo/provisions/moss-mix/"` under `base: "/repo/"`, and the URL as it is without one. See [Serving a site under a path](https://sitesquatch.dev/docs/deploying/index.md#serving-a-site-under-a-path).
- `absoluteUrl`: The `absoluteUrl` template function, for a site's own code: `absoluteUrl("/provisions/moss-mix/", "https://example.com")` is `"https://example.com/repo/provisions/moss-mix/"` under `base: "/repo/"`: the site's `base` goes in front of a URL from the root that doesn't have it yet, then the URL is resolved against the address, as `new URL()` does. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/image"

- `imagePlugin`: Turns every local `<img>` in HTML output into a `<picture>`, with AVIF, WebP and fallback sources encoded by sharp. See [Quality numbers from 0.7](https://sitesquatch.dev/docs/plugins/index.md#quality-numbers-from-07).
- `image`: Generate one image's files with the plugin's settings and cache. See [Images](https://sitesquatch.dev/docs/plugins/index.md#images).
- `imageUrl`: The URL (and size and type) of one generated copy of an image, for `og:image`, JSON-LD and feeds: `imageUrl("/content/logo.png", { width: 1200 })`. See [Images](https://sitesquatch.dev/docs/plugins/index.md#images).

## From "ssqch/rss"

- `rssPlugin`: Adds the filters getNewestCollectionItemDate, dateToRfc3339, dateToRfc822, htmlToAbsoluteUrls and feedHtml. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `feedPlugin`: Writes the site's feed (Atom, or RSS) from a collection, newest first, each entry's content as feedHtml makes it: `feedPlugin({ url: "https://example.com" })` writes /feed.xml from the `posts` collection. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `getNewestCollectionItemDate`: The newest `date` in a collection, for a feed's `updated`. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `dateToRfc3339`: A date as RFC 3339 (`2024-06-01T00:00:00Z`), for Atom feeds. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `dateToRfc822`: A date as RFC 822 (`Sat, 01 Jun 2024 00:00:00 +0000`), for RSS feeds. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `absoluteUrl`: A URL made absolute against the site's address: `absoluteUrl(post.url, "https://example.com")`, with the site's `base` in front of a URL from the root that doesn't have it yet, as the template function does. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `htmlToAbsoluteUrls`: Every link and image in some HTML made absolute, for a feed's content, with the site's `base` in front of a URL from the root, as `absoluteUrl` does. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `feedHtml`: A post's HTML for a feed: each local image points at one generated copy (`width` 1200 and the source's format by default), a `<picture>`'s `<source srcset>` goes, page-only attributes go, and every URL is made absolute against `base`, the post's address. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/minify"

- `minifyPlugin`: Minifies HTML output, after the image transform, with ssqch's own minifier (Rust, as WebAssembly): it doesn't write html-minifier-terser's bytes. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `minify`: Minify one string of HTML, with the plugin's options. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
- `minifyCss`: Compress CSS text as `style: "compressed"` Sass writes it (`.a{color:#fff}`), for CSS inlined by a template: `{{ css | minifyCss }}` in a filter of your own. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/assets"

- `assetsPlugin`: Renames each file to `name.<hash>.ext` in production builds and rewrites the links to it. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/links"

- `linksPlugin`: Checks every internal link and anchor after each build: in HTML attributes, `<meta>` URLs, JSON-LD, and feeds and other XML. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/sitemap"

- `sitemapPlugin`: Writes `sitemap.xml` listing every HTML page. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/from-vitepress"

- `fromVitepress`: VitePress's Markdown, for a site moving from VitePress, and VitePress's ways for `vuePlugin()`'s components (`useData()` and the rest from "vitepress", `@theme/`, and `./x.data` imports running its data loaders): Vue's `<script>` and `<style>` blocks and `<ClientOnly>` left out, VitePress's markup for headings (`header-anchor`), links (`.html` with `urls: "html"`, external ones in a new tab), code blocks and tables, its `tip`, `info`, `warning`, `danger`, `details`, `raw` and `code-group` containers, `[[toc]]`, and, under the site's own `markdown` options, its heading ids and email autolinks. See [Plugins that come with ssqch](https://sitesquatch.dev/docs/writing-plugins/index.md#plugins-that-come-with-ssqch).

## From "ssqch/from-mkdocs"

- `fromMkdocs`: MkDocs' Markdown for a site moving from MkDocs, each a default under the site's own `markdown` options: Python-Markdown's reading (`dialect: "python-markdown"`: raw HTML blocks to their closing tag, lists at four spaces), its toc's heading ids, `!!! note` admonitions and `=== "Tab"` tabs as Material writes them, and `.md` links from the page; and with `templates`, MkDocs' context for a theme's templates. See [Plugins that come with ssqch](https://sitesquatch.dev/docs/writing-plugins/index.md#plugins-that-come-with-ssqch).

## From "ssqch/from-jekyll"

- `fromJekyll`: What a Jekyll site's templates and Markdown expect, for a site moving from Jekyll: Jekyll's `page` and `site` in templates, and kramdown's Markdown. See [Plugins that come with ssqch](https://sitesquatch.dev/docs/writing-plugins/index.md#plugins-that-come-with-ssqch).

## From "ssqch/from-hugo"

- `fromHugo`: Hugo's shortcodes for a site moving from Hugo, as a default under the site's own `markdown` options (`shortcodes: "hugo"`): a shortcode on a line of its own (`{{< note type="tip" >}}` to `{{< /note >}}`, or `{{% %}}`) is a container rendered by `_includes/containers/<name>.*`, with its arguments as `container.props`, and one inside a line of text renders the same template in its place, with `container.inline` true. See [Plugins that come with ssqch](https://sitesquatch.dev/docs/writing-plugins/index.md#plugins-that-come-with-ssqch).

## From "ssqch/vue"

- `vuePlugin`: Renders the Vue components a page uses (`<ApiIndex />`, imported in its `<script setup>`) with the site's own Vite, @vitejs/plugin-vue and Vue, at build time; with `hydrate`, as islands in the browser too. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/react"

- `reactPlugin`: Renders the React components a page uses (`<Counter start={3} />`, imported in the page as MDX does or named in `components`) with the site's own React, react-dom and esbuild, at build time; with `hydrate`, as islands in the browser too. See [React components](https://sitesquatch.dev/docs/plugins/index.md#react-components).

## From "ssqch/llms"

- `llmsPlugin`: Writes `/llms.txt` (the site's pages, with links to their Markdown), a Markdown copy of each, and `/llms-full.txt`, for language models, as llmstxt.org describes; and adds the template functions `markdownCopy(page.url)`, the URL of a page's copy (or `""` when it has none), for a layout's `<link rel="alternate" type="text/markdown">`, and `llmsTxt(page.url)`, the `llms.txt` that covers the page, for its `<link rel="describedby">`. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/robots"

- `robotsPlugin`: Writes `/robots.txt`: the paths no crawler reads, a group for each kind of AI crawler that's turned off, and the sitemap's address. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/elements"

- `elementsPlugin`: Custom elements: `like-button.js` in the elements folder loads on the pages that have a `<like-button>`, and nowhere else. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/redirects"

- `redirectsPlugin`: Redirects from each page's `aliases` front matter and from `redirects`. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).

## From "ssqch/sass"

- `sassPlugin`: Compiles Sass at the start of each build, with grass (Rust, as WebAssembly: no Dart Sass), so fingerprinting and the link checker see the CSS. See [The gear shed: built-in plugins](https://sitesquatch.dev/docs/plugins/index.md).
