Scan your whole stack
Are you using satteri-autolink-headings?
Find out what’s in your code.
Scan your apps free in minutes (opens in a new tab)Latest version: v0.3.1
satteri-autolink-headings was last scanned on 30 Nov 2026 at version 0.3.1. Risk score 0 of 100. No malicious behavior was detected.
| Version | Published | Status |
|---|---|---|
| 0.3.1 LATEST | 30 Nov 2026 | No rules fired |
| 0.3.0 | 29 Oct 2026 | No rules fired |
| 0.2.0 | 23 Oct 2026 | No rules fired |
Findings for v0.3.1. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.
The score describes 0.3.1; other versions have their own rules, not their own score.
The publisher’s own README, as collected from the registry.
Sätteri HAST plugin that adds a link to every heading — a port of
rehype-autolink-headings.
Pair it with satteri-slug, which supplies the id this plugin links to.
Headings without an id are skipped.
npm install satteri-slug satteri-autolink-headings
import { markdownToHtml } from "satteri";
import { satteriSlug } from "satteri-slug";
import { satteriAutolinkHeadings } from "satteri-autolink-headings";
const { html } = markdownToHtml("## Hello World", {
hastPlugins: [satteriSlug(), satteriAutolinkHeadings()],
});
// <h2 id="hello-world"><a aria-hidden="true" tabindex="-1" href="#hello-world">
// <span class="icon icon-link"></span></a>Hello World</h2>
Order matters: Sätteri runs HAST plugins in array order, so satteriSlug() must come first.
In Astro this is not optional. Astro's Sätteri processor assigns heading ids with its own plugin
appended after your HAST plugins, so at the point this plugin runs the headings still have no
id and every heading is skipped. Including satteriSlug() is what makes the anchors appear —
in the example site, dropping it takes the anchor count from 10 to 1.
With Astro 7:
// astro.config.mjs
import { defineConfig } from "astro/config";
import { satteri } from "@astrojs/markdown-satteri";
import { satteriSlug } from "satteri-slug";
import { satteriAutolinkHeadings } from "satteri-autolink-headings";
export default defineConfig({
markdown: {
processor: satteri({
hastPlugins: [satteriSlug(), satteriAutolinkHeadings({ behavior: "wrap" })],
}),
},
});
satteriAutolinkHeadings(options?)options.behavior"prepend" (default) · "append" · "wrap" · "before" · "after"
<!-- prepend --> <h2 id="x"><a href="#x">…</a>Text</h2>
<!-- append --> <h2 id="x">Text<a href="#x">…</a></h2>
<!-- wrap --> <h2 id="x"><a href="#x">Text</a></h2>
<!-- before --> <a href="#x">…</a><h2 id="x">Text</h2>
<!-- after --> <h2 id="x">Text</h2><a href="#x">…</a>
options.contentA hast node, an array of them, or a function of the heading. Defaults to
<span class="icon icon-link"></span> — except for wrap, which defaults to nothing.
satteriAutolinkHeadings({ content: { type: "text", value: "#" } });
satteriAutolinkHeadings({ content: (heading) => ({ type: "text", value: heading.tagName }) });
options.propertiesProperties of the <a>, as an object or a function of the heading. Replaces the defaults rather
than merging with them (matching rehype-autolink-headings). Defaults to
{ ariaHidden: "true", tabIndex: -1 } for prepend/append, and {} for the rest. href is
always set from the heading id.
options.headingPropertiesExtra properties merged onto the heading element itself.
options.testHeading tag names to link. Default ["h1", …, "h6"].
satteriAutolinkHeadings({ test: ["h2", "h3"] });
options.groupAn element wrapping the link and the heading together. Only meaningful with before/after.
satteriAutolinkHeadings({
behavior: "before",
group: { type: "element", tagName: "div", properties: { className: ["g"] }, children: [] },
});
// <div class="g"><a href="#x">…</a><h2 id="x">Text</h2></div>
rehype-autolink-headingssatteriAutolinkHeadings({…})) rather than via unified().use().options.test accepts a list of tag names, not a hast-util-is-element test function. Sätteri
filters by tag name at the engine level, which is where its speed comes from.contentProperties is not implemented — it has no observable effect in rehype-autolink-headings
v7 for the content shapes people actually pass.MIT © Ashish Vaghela
Find threats in your stack.
OX Radar can check high-priority threats, like critical package CVEs, against your context.
Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.
The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).
The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.