Skip to content

anchor()

ts
function anchor(value): Node;

Defined in: anchor.ts:26

Builder-element for an custom anchor

Parameters

ParameterTypeDescription
valuestring | NodeContent of this element

Returns

Node

A markdown node

Example

ts
import { define, anchor } from "@ogs-gmbh/markdown";

const markdown = define(
  anchor("my-custom-anchor")
);

console.assert(
  markdown.toString()
);

See

https://vitepress.dev/guide/markdown#custom-anchors

Since

1.0.0

Author

Simon Kovtyk