npm.io
0.22.1 • Published 2 months ago

@dprint/markdown

Licence
MIT
Version
0.22.1
Deps
0
Size
2.0 MB
Vulns
0
Weekly
0
Stars
54

@dprint/markdown

npm distribution of dprint-plugin-markdown.

Use this with @dprint/formatter or just use @dprint/formatter and download the dprint-plugin-markdown WASM file.

Example

import { createFromBuffer } from "@dprint/formatter";
import { getPath } from "@dprint/markdown";
import * as fs from "fs";

const buffer = fs.readFileSync(getPath());
const formatter = createFromBuffer(buffer);

console.log(formatter.formatText("test.md", "#   Some Title    "));

Keywords