# transform.ts

**[Source](https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts)**

> 12 documented symbols. Read the signatures first, then expand each item for parameters, return types, and examples.

<div class="ox-api-stats" aria-label="API reference summary">
<span class="ox-api-stat">
  <strong>12</strong>
  <span>symbols</span>
</span>
<span class="ox-api-stat">
  <strong>5</strong>
  <span>functions</span>
</span>
<span class="ox-api-stat">
  <strong>5</strong>
  <span>interfaces</span>
</span>
<span class="ox-api-stat">
  <strong>1</strong>
  <span>variables</span>
</span>
<span class="ox-api-stat">
  <strong>1</strong>
  <span>modules</span>
</span>
<span class="ox-api-stat">
  <strong>21</strong>
  <span>parameters</span>
</span>
<span class="ox-api-stat">
  <strong>73</strong>
  <span>members</span>
</span>
<span class="ox-api-stat">
  <strong>5</strong>
  <span>returns</span>
</span>
<span class="ox-api-stat">
  <strong>1</strong>
  <span>examples</span>
</span>
</div>

## Reference

<div class="ox-api-controls" data-ox-api-target=".ox-api-entry" role="toolbar" aria-label="Reference display controls">
<button type="button" class="ox-api-controls__button" data-ox-api-toggle="expand">Open all</button>
<button type="button" class="ox-api-controls__button" data-ox-api-toggle="collapse">Close all</button>
</div>

<details id="extractimports" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">fn</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">extractImports(content: string): string[]</code><span class="ox-api-entry__description">Extracts imports from Markdown content. Supports importing components for inter…</span><span class="ox-api-entry__meta"><span class="ox-api-badge">1 param</span><span class="ox-api-badge">returns string[]</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>Extracts imports from Markdown content.</p>
<p>Supports importing components for interactive islands.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">export function extractImports(content: string): string[]</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L1214-L1224" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--params">
<h4>Parameters</h4>
<ul class="ox-api-entry__params">
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">content</code>
    <code class="ox-api-entry__param-type">string</code>
  </div>
</li>
</ul>
</div>
<div class="ox-api-entry__section ox-api-entry__section--returns">
<h4>Returns</h4>
<div class="ox-api-entry__return">
  <code class="ox-api-entry__return-type">string[]</code>
</div>
</div>
  </div>
</details>

<details id="generatemodulecode" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">fn</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">generateModuleCode(html: string, frontmatter: Record&lt;string, unknown&gt;, toc: TocEntry[], imports: MdxImport[], exports: string[], components: string[], crossReferences: CrossReferenceEntry[], citations: CitationReference[], bibliography: BibliographyEntry[], filePath: string): string</code><span class="ox-api-entry__description">Generates the JavaScript module code. MDX metadata is serialized as JSON. User…</span><span class="ox-api-entry__meta"><span class="ox-api-badge">10 params</span><span class="ox-api-badge">returns string</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>Generates the JavaScript module code.</p>
<p>MDX metadata is serialized as JSON. User <code>import</code> / <code>export</code> source is never emitted as live JavaScript, so transform does not execute module side effects.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">function generateModuleCode(html: string, frontmatter: Record&lt;string, unknown&gt;, toc: TocEntry[], imports: MdxImport[], exports: string[], components: string[], crossReferences: CrossReferenceEntry[], citations: CitationReference[], bibliography: BibliographyEntry[], filePath: string): string</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L1111-L1207" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--params">
<h4>Parameters</h4>
<ul class="ox-api-entry__params">
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">html</code>
    <code class="ox-api-entry__param-type">string</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">frontmatter</code>
    <code class="ox-api-entry__param-type">Record&lt;string, unknown&gt;</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">toc</code>
    <code class="ox-api-entry__param-type"><a href="./types.md#tocentry">TocEntry</a>[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">imports</code>
    <code class="ox-api-entry__param-type"><a href="./types.md#mdximport">MdxImport</a>[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">exports</code>
    <code class="ox-api-entry__param-type">string[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">components</code>
    <code class="ox-api-entry__param-type">string[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">crossReferences</code>
    <code class="ox-api-entry__param-type">CrossReferenceEntry[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">citations</code>
    <code class="ox-api-entry__param-type">CitationReference[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">bibliography</code>
    <code class="ox-api-entry__param-type">BibliographyEntry[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">filePath</code>
    <code class="ox-api-entry__param-type">string</code>
  </div>
</li>
</ul>
</div>
<div class="ox-api-entry__section ox-api-entry__section--returns">
<h4>Returns</h4>
<div class="ox-api-entry__return">
  <code class="ox-api-entry__return-type">string</code>
</div>
</div>
  </div>
</details>

<details id="generateogimagesvg" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">fn</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">generateOgImageSvg(data: OgImageData, config?: OgImageConfig): Promise&lt;string | null&gt;</code><span class="ox-api-entry__description">Generates an OG image SVG using the Rust-based generator. This function uses th…</span><span class="ox-api-entry__meta"><span class="ox-api-badge">2 params</span><span class="ox-api-badge">returns Promise&lt;string | null&gt;</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>Generates an OG image SVG using the Rust-based generator.</p>
<p>This function uses the Rust NAPI bindings to generate SVG-based OG images for social media previews. The SVG can be served directly or converted to PNG/JPEG for broader compatibility.</p>
<p>In the future, custom JS templates can be provided to override the default Rust-based template.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">export async function generateOgImageSvg(data: OgImageData, config?: OgImageConfig): Promise&lt;string | null&gt;</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L1240-L1262" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--params">
<h4>Parameters</h4>
<ul class="ox-api-entry__params">
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">data</code>
    <code class="ox-api-entry__param-type"><a href="#ogimagedata">OgImageData</a></code>
  </div>
  <p class="ox-api-entry__param-description">OG image data (title, description, etc.)</p>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">config</code>
    <code class="ox-api-entry__param-type"><a href="#ogimageconfig">OgImageConfig</a></code>
  </div>
  <p class="ox-api-entry__param-description">Optional OG image configuration — optional</p>
</li>
</ul>
</div>
<div class="ox-api-entry__section ox-api-entry__section--returns">
<h4>Returns</h4>
<div class="ox-api-entry__return">
  <code class="ox-api-entry__return-type">Promise&lt;string | null&gt;</code>
  <p class="ox-api-entry__return-description">SVG string or null if NAPI bindings are unavailable</p>
</div>
</div>
  </div>
</details>

<details id="jstransformoptions" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">interface</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">JsTransformOptions</code><span class="ox-api-entry__description">Options for Rust-based Markdown transformation. Controls which Markdown extensi…</span><span class="ox-api-entry__meta"><span class="ox-api-badge">52 members</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>Options for Rust-based Markdown transformation.</p>
<p>Controls which Markdown extensions and features are enabled during parsing and rendering.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">interface JsTransformOptions</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L203-L494" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--members">
<h4>Members</h4>
<div class="ox-api-entry__member-group">
<h5>Properties</h5>
<table class="ox-api-entry__members-table">
<thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead>
<tbody>
<tr id="jstransformoptions-abbreviations">
  <td><code>abbreviations</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; terms?: Record&lt;string, string&gt;; firstUseOnly?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-attributes">
  <td><code>attributes</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-autolinks">
  <td><code>autolinks</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable automatic link conversion (URLs become clickable).</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-autolinktargetblank">
  <td><code>autolinkTargetBlank</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Add <code>target=&quot;_blank&quot; rel=&quot;noopener noreferrer&quot;</code> to linkified bare URLs.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">true</code></div></td>
</tr>
<tr id="jstransformoptions-autolinkurls">
  <td><code>autolinkUrls</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Linkify bare URLs while rendering.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">true</code></div></td>
</tr>
<tr id="jstransformoptions-badges">
  <td><code>badges</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-baseurl">
  <td><code>baseUrl</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Base URL for absolute link conversion (e.g., &quot;/&quot; or &quot;/docs/&quot;).</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">&quot;/&quot;</code></div></td>
</tr>
<tr id="jstransformoptions-cards">
  <td><code>cards</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-cjkemphasis">
  <td><code>cjkEmphasis</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-codeannotationdefaultlinenumbers">
  <td><code>codeAnnotationDefaultLineNumbers</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable line numbers for all code blocks by default.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-codeannotationmetakey">
  <td><code>codeAnnotationMetaKey</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Fence meta key used to read code annotations.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">&quot;annotate&quot;</code></div></td>
</tr>
<tr id="jstransformoptions-codeannotations">
  <td><code>codeAnnotations</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable line annotations for code blocks using fence meta.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-codeannotationsyntax">
  <td><code>codeAnnotationSyntax</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">&quot;attribute&quot; | &quot;vitepress&quot; | &quot;both&quot;</code></td>
  <td><div class="ox-api-entry__member-description">Code annotation syntax mode.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">&quot;attribute&quot;</code></div></td>
</tr>
<tr id="jstransformoptions-codegroups">
  <td><code>codeGroups</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-codeimports">
  <td><code>codeImports</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; rootDir?: string }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-conditionalblocks">
  <td><code>conditionalBlocks</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; values?: Record&lt;string, unknown&gt; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-containers">
  <td><code>containers</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; types?: Record&lt;string, { title?: string; tag?: string }&gt; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-convertmdlinks">
  <td><code>convertMdLinks</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Convert <code>.md</code> links to <code>.html</code> links for SSG output.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-datatables">
  <td><code>dataTables</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; rootDir?: string; missing?: &quot;error&quot; | &quot;warn&quot; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-definitionlists">
  <td><code>definitionLists</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-editthispage">
  <td><code>editThisPage</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; repoUrl?: string; branch?: string; rootDir?: string; srcDir?: string; provider?: string; urlPattern?: string; label?: string }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-emojishortcodes">
  <td><code>emojiShortcodes</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; custom?: Record&lt;string, string&gt; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-filetree">
  <td><code>fileTree</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; defaultOpen?: boolean; icons?: boolean; iconFolder?: string; iconFolderOpen?: string; iconFile?: string; iconFiles?: Record&lt;string, string&gt; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-footnotes">
  <td><code>footnotes</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable footnotes syntax ([^1]: definition).</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-frontmatter">
  <td><code>frontmatter</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Parse YAML frontmatter before transforming.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">true</code></div></td>
</tr>
<tr id="jstransformoptions-gfm">
  <td><code>gfm</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable GitHub Flavored Markdown extensions.<br>Includes tables, task lists, strikethrough, and autolinks.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-headingattributes">
  <td><code>headingAttributes</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-headingpermalinks">
  <td><code>headingPermalinks</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Append visible heading permalinks.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-imagegalleries">
  <td><code>imageGalleries</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; lazy?: boolean; missingAlt?: &quot;error&quot; | &quot;warn&quot; | &quot;ignore&quot;; empty?: &quot;error&quot; | &quot;warn&quot; | &quot;ignore&quot; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-images">
  <td><code>images</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; lazy?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-includes">
  <td><code>includes</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; rootDir?: string }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-keyboardkeys">
  <td><code>keyboardKeys</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; aliases?: Record&lt;string, string&gt;; style?: string }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-linktargetblank">
  <td><code>linkTargetBlank</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Add <code>target=&quot;_blank&quot; rel=&quot;noopener noreferrer&quot;</code> to parsed http(s) Markdown links.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">true</code></div></td>
</tr>
<tr id="jstransformoptions-magiclinks">
  <td><code>magicLinks</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; aliases?: Record&lt;string, { href: string; label?: string; image?: string }&gt;; favicon?: boolean; faviconTemplate?: string; imageOverrides?: Array&lt;{ href?: string; prefix?: string; image: string }&gt; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-math">
  <td><code>math</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean | { enabled?: boolean }</code></td>
  <td><div class="ox-api-entry__member-description">Opt-in <code>$…$</code> inline and <code>$$…$$</code> block math.<br><br>Omitted or <code>false</code> leaves <code>$</code> literal. <code>true</code> or <code>{}</code> enables defaults;<br><code>{ enabled: false }</code> disables math.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-mdx">
  <td><code>mdx</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable MDX JSX, ESM, and expression nodes.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-notbyai">
  <td><code>notByAi</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; label?: string; href?: string }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-partials">
  <td><code>partials</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; rootDir?: string; root?: string; missing?: string }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-sanitize">
  <td><code>sanitize</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">JsSanitizeOptions</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-semanticfootnotes">
  <td><code>semanticFootnotes</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Render footnotes as a semantic ordered section with numeric markers.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-smartpunctuation">
  <td><code>smartPunctuation</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-sourcepath">
  <td><code>sourcePath</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Source file path for relative link resolution.<br>Used to determine if the current file is an index file.</div></td>
</tr>
<tr id="jstransformoptions-sourcespans">
  <td><code>sourceSpans</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Emit <code>data-source-span=&quot;start-end&quot;</code> on rendered block elements.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-steps">
  <td><code>steps</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-strikethrough">
  <td><code>strikethrough</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable strikethrough syntax (~~text~~).<br>Requires GFM to be enabled.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-subscript">
  <td><code>subscript</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-superscript">
  <td><code>superscript</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-tables">
  <td><code>tables</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable table rendering (GFM extension).<br>Requires GFM to be enabled for full functionality.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-tasklists">
  <td><code>taskLists</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Enable task list syntax (- [ ] unchecked, - [x] checked).</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">false</code></div></td>
</tr>
<tr id="jstransformoptions-timelines">
  <td><code>timelines</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; ordered?: boolean; invalidDate?: &quot;error&quot; | &quot;warn&quot; | &quot;ignore&quot;; unknownMeta?: &quot;error&quot; | &quot;warn&quot; | &quot;ignore&quot;; empty?: &quot;error&quot; | &quot;warn&quot; | &quot;ignore&quot; }</code></td>
  <td></td>
</tr>
<tr id="jstransformoptions-tocmaxdepth">
  <td><code>tocMaxDepth</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">number</code></td>
  <td><div class="ox-api-entry__member-description">Maximum heading depth for table of contents.<br>Headings deeper than this level are excluded from TOC.</div><div class="ox-api-entry__member-default"><span>Default</span> <code class="language-typescript">3</code></div></td>
</tr>
<tr id="jstransformoptions-wikilinks">
  <td><code>wikiLinks</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">{ enabled?: boolean; baseUrl?: string }</code></td>
  <td></td>
</tr>
</tbody>
</table>
</div>
</div>
  </div>
</details>

<details id="napitransformresult" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">interface</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">NapiTransformResult</code><span class="ox-api-entry__description">What the native transform entry points return.</span><span class="ox-api-entry__meta"><span class="ox-api-badge">7 members</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>What the native transform entry points return.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">interface NapiTransformResult</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L82-L90" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--members">
<h4>Members</h4>
<div class="ox-api-entry__member-group">
<h5>Properties</h5>
<table class="ox-api-entry__members-table">
<thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead>
<tbody>
<tr id="napitransformresult-components">
  <td><code>components</code></td>
  <td><code class="ox-api-entry__member-type language-typescript">string[]</code></td>
  <td></td>
</tr>
<tr id="napitransformresult-errors">
  <td><code>errors</code></td>
  <td><code class="ox-api-entry__member-type language-typescript">string[]</code></td>
  <td></td>
</tr>
<tr id="napitransformresult-exports">
  <td><code>exports</code></td>
  <td><code class="ox-api-entry__member-type language-typescript">string[]</code></td>
  <td></td>
</tr>
<tr id="napitransformresult-frontmatter">
  <td><code>frontmatter</code></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td></td>
</tr>
<tr id="napitransformresult-html">
  <td><code>html</code></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td></td>
</tr>
<tr id="napitransformresult-imports">
  <td><code>imports</code></td>
  <td><code class="ox-api-entry__member-type language-typescript"><a href="./types.md#mdximport">MdxImport</a>[]</code></td>
  <td></td>
</tr>
<tr id="napitransformresult-toc">
  <td><code>toc</code></td>
  <td><code class="ox-api-entry__member-type language-typescript">Array&lt;{ depth: number; text: string; slug: string; children?: <a href="./types.md#tocentry">TocEntry</a>[] }&gt;</code></td>
  <td></td>
</tr>
</tbody>
</table>
</div>
</div>
  </div>
</details>

<details id="ogimageconfig" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">interface</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">OgImageConfig</code><span class="ox-api-entry__description">OG image configuration.</span><span class="ox-api-entry__meta"><span class="ox-api-badge">6 members</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>OG image configuration.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">export interface OgImageConfig</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L182-L195" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--members">
<h4>Members</h4>
<div class="ox-api-entry__member-group">
<h5>Properties</h5>
<table class="ox-api-entry__members-table">
<thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead>
<tbody>
<tr id="ogimageconfig-backgroundcolor">
  <td><code>backgroundColor</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Background color (hex)</div></td>
</tr>
<tr id="ogimageconfig-descriptionfontsize">
  <td><code>descriptionFontSize</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">number</code></td>
  <td><div class="ox-api-entry__member-description">Description font size</div></td>
</tr>
<tr id="ogimageconfig-height">
  <td><code>height</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">number</code></td>
  <td><div class="ox-api-entry__member-description">Image height in pixels</div></td>
</tr>
<tr id="ogimageconfig-textcolor">
  <td><code>textColor</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Text color (hex)</div></td>
</tr>
<tr id="ogimageconfig-titlefontsize">
  <td><code>titleFontSize</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">number</code></td>
  <td><div class="ox-api-entry__member-description">Title font size</div></td>
</tr>
<tr id="ogimageconfig-width">
  <td><code>width</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">number</code></td>
  <td><div class="ox-api-entry__member-description">Image width in pixels</div></td>
</tr>
</tbody>
</table>
</div>
</div>
  </div>
</details>

<details id="ogimagedata" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">interface</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">OgImageData</code><span class="ox-api-entry__description">OG image data for generating social media preview images.</span><span class="ox-api-entry__meta"><span class="ox-api-badge">4 members</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>OG image data for generating social media preview images.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">export interface OgImageData</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L168-L177" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--members">
<h4>Members</h4>
<div class="ox-api-entry__member-group">
<h5>Properties</h5>
<table class="ox-api-entry__members-table">
<thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead>
<tbody>
<tr id="ogimagedata-author">
  <td><code>author</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Author name</div></td>
</tr>
<tr id="ogimagedata-description">
  <td><code>description</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Page description</div></td>
</tr>
<tr id="ogimagedata-sitename">
  <td><code>siteName</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Site name</div></td>
</tr>
<tr id="ogimagedata-title">
  <td><code>title</code></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Page title</div></td>
</tr>
</tbody>
</table>
</div>
</div>
  </div>
</details>

<details id="runtransformers" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">fn</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">runTransformers(napi: NapiBindings, markdown: string, napiOptions: JsTransformOptions, filePath: string, options: ResolvedOptions, transformers: readonly MarkdownTransformer[]): Promise&lt;NapiTransformResult&gt;</code><span class="ox-api-entry__description">Runs the configured transformers over the parsed tree. Markdown never passes th…</span><span class="ox-api-entry__meta"><span class="ox-api-badge">6 params</span><span class="ox-api-badge">returns Promise&lt;NapiTransformResult&gt;</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>Runs the configured <code>transformers</code> over the parsed tree.</p>
<p>Markdown never passes through Vite&#39;s <code>transform</code> hook — the native layer reads it directly — so this is the only place user config can reach the AST. The tree is handed over after frontmatter parsing and Markdown feature expansion, and handed back for rendering, HTML postprocessing, and sanitization, so a transformer costs a document nothing else.</p>
<p>A transformer that throws, or returns something that is not a node, is reported and skipped: one bad hook should not take the page down with it.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">async function runTransformers(napi: NapiBindings, markdown: string, napiOptions: JsTransformOptions, filePath: string, options: ResolvedOptions, transformers: readonly MarkdownTransformer[]): Promise&lt;NapiTransformResult&gt;</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L1026-L1074" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--params">
<h4>Parameters</h4>
<ul class="ox-api-entry__params">
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">napi</code>
    <code class="ox-api-entry__param-type">NapiBindings</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">markdown</code>
    <code class="ox-api-entry__param-type">string</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">napiOptions</code>
    <code class="ox-api-entry__param-type"><a href="#jstransformoptions">JsTransformOptions</a></code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">filePath</code>
    <code class="ox-api-entry__param-type">string</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">options</code>
    <code class="ox-api-entry__param-type"><a href="./types.md#resolvedoptions">ResolvedOptions</a></code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">transformers</code>
    <code class="ox-api-entry__param-type">readonly <a href="./types.md#markdowntransformer">MarkdownTransformer</a>[]</code>
  </div>
</li>
</ul>
</div>
<div class="ox-api-entry__section ox-api-entry__section--returns">
<h4>Returns</h4>
<div class="ox-api-entry__return">
  <code class="ox-api-entry__return-type">Promise&lt;<a href="#napitransformresult">NapiTransformResult</a>&gt;</code>
</div>
</div>
  </div>
</details>

<details id="ssgtransformoptions" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">interface</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">SsgTransformOptions</code><span class="ox-api-entry__description">SSG-specific transform options.</span><span class="ox-api-entry__meta"><span class="ox-api-badge">4 members</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>SSG-specific transform options.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">export interface SsgTransformOptions</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L674-L683" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--members">
<h4>Members</h4>
<div class="ox-api-entry__member-group">
<h5>Properties</h5>
<table class="ox-api-entry__members-table">
<thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead>
<tbody>
<tr id="ssgtransformoptions-baseurl">
  <td><code>baseUrl</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Base URL for absolute link conversion</div></td>
</tr>
<tr id="ssgtransformoptions-convertmdlinks">
  <td><code>convertMdLinks</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">boolean</code></td>
  <td><div class="ox-api-entry__member-description">Convert <code>.md</code> links to <code>.html</code> links</div></td>
</tr>
<tr id="ssgtransformoptions-sourcepath">
  <td><code>sourcePath</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Source file path for relative link resolution</div></td>
</tr>
<tr id="ssgtransformoptions-srcdir">
  <td><code>srcDir</code><span class="ox-api-badge">optional</span></td>
  <td><code class="ox-api-entry__member-type language-typescript">string</code></td>
  <td><div class="ox-api-entry__member-description">Absolute source root, used to place pages inside the repository</div></td>
</tr>
</tbody>
</table>
</div>
</div>
  </div>
</details>

<details id="transform" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">module</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__name">transform</code><span class="ox-api-entry__description">Markdown Transformation Engine This module handles the complete transformation pipeline for Markdown files, converting…</span><span class="ox-api-entry__meta"><span class="ox-api-badge">1 example</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>Markdown Transformation Engine</p>
<p>This module handles the complete transformation pipeline for Markdown files, converting raw Markdown content into JavaScript modules that can be imported by web applications. The transformation process includes:</p>
<ol>
<li><strong>Parsing</strong>: Uses Rust-based parser via NAPI bindings for high performance</li>
<li><strong>Rendering</strong>: Converts parsed AST to semantic HTML</li>
<li><strong>Enhancement</strong>: Applies syntax highlighting, Mermaid diagram rendering, etc.</li>
<li><strong>Code Generation</strong>: Generates JavaScript/TypeScript module code</li>
</ol>
<p>The generated modules export:</p>
<ul>
<li><code>html</code>: Rendered HTML content</li>
<li><code>frontmatter</code>: Parsed YAML metadata</li>
<li><code>toc</code>: Hierarchical table of contents</li>
<li><code>imports</code>: MDX import statements from the AST</li>
<li><code>exports</code>: MDX export names from the AST</li>
<li><code>components</code>: Unique JSX component names from the AST</li>
<li><code>render</code>: Client-side render function for dynamic updates</li>
</ul>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L1-L35" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--examples">
<h4>Examples</h4>
<div class="ox-api-entry__example">
<div class="ox-api-entry__example-heading">Example 1</div>
<pre><code class="language-typescript">import { transformMarkdown } from &#39;./transform&#39;;&#10;
const content = await transformMarkdown(
  &#39;# Hello\n\nWorld&#39;,
  &#39;path/to/file.md&#39;,
  resolvedOptions
);&#10;
console.log(content.html); // &#39;&lt;h1&gt;Hello&lt;/h1&gt;&lt;p&gt;World&lt;/p&gt;&#39;
console.log(content.toc);  // [{ depth: 1, text: &#39;Hello&#39;, slug: &#39;hello&#39;, children: [] }]</code></pre>
</div>
</div>
  </div>
</details>

<details id="unhighlighted_code_block" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">variable</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">const UNHIGHLIGHTED_CODE_BLOCK = /&lt;pre(?![^&gt;]*ox-highlight)[^&gt;]*&gt;&lt;code class=&quot;language-/</code><span class="ox-api-entry__description">A &lt;pre&gt; that names a language but has not been highlighted yet.</span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>A <code>&lt;pre&gt;</code> that names a language but has not been highlighted yet.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">const UNHIGHLIGHTED_CODE_BLOCK = /&lt;pre(?![^&gt;]*ox-highlight)[^&gt;]*&gt;&lt;code class=&quot;language-/</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L49" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
  </div>
</details>

<details id="warnmathfailures" class="ox-api-entry">
  <summary><span class="ox-api-entry__kind">fn</span><span class="ox-api-entry__summary-main"><code class="ox-api-entry__signature ox-api-entry__signature--highlighted language-typescript">warnMathFailures(failures: MathRenderFailure[], filePath: string): void</code><span class="ox-api-entry__description">Reports every $…$ run KaTeX refused. Under the default policy the page keeps it…</span><span class="ox-api-entry__meta"><span class="ox-api-badge">2 params</span><span class="ox-api-badge">returns void</span></span></span></summary>
  <div class="ox-api-entry__body">
<div class="ox-api-entry__prose">
<p>Reports every <code>$…$</code> run KaTeX refused.</p>
<p>Under the default policy the page keeps its prose, which is the readable outcome but also a silent one — a genuine mistake in a formula would otherwise leave no trace at all.</p>
</div>
<div class="ox-api-entry__section ox-api-entry__section--signature">
<h4>Signature</h4>
<pre><code class="language-typescript">function warnMathFailures(failures: MathRenderFailure[], filePath: string): void</code></pre>
</div>
<p class="ox-api-entry__source"><a class="ox-api-entry__source-link" href="https://github.com/ubugeeei-prod/ox-content/blob/main/npm/vite-plugin-ox-content/src/transform.ts#L1271-L1279" target="_blank" rel="noopener noreferrer">View source<span class="ox-api-entry__source-icon" aria-hidden="true"></span></a></p>
<div class="ox-api-entry__section ox-api-entry__section--params">
<h4>Parameters</h4>
<ul class="ox-api-entry__params">
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">failures</code>
    <code class="ox-api-entry__param-type"><a href="./math.md#mathrenderfailure">MathRenderFailure</a>[]</code>
  </div>
</li>
<li class="ox-api-entry__param">
  <div class="ox-api-entry__param-heading">
    <code class="ox-api-entry__param-name">filePath</code>
    <code class="ox-api-entry__param-type">string</code>
  </div>
</li>
</ul>
</div>
<div class="ox-api-entry__section ox-api-entry__section--returns">
<h4>Returns</h4>
<div class="ox-api-entry__return">
  <code class="ox-api-entry__return-type">void</code>
</div>
</div>
  </div>
</details>
