smarkdown

Markdown parser, simplicity and extensibility.

Usage no npm install needed!

<script type="module">
  import smarkdown from 'https://cdn.skypack.dev/smarkdown';
</script>

README

smarkdown

npm gzip size install size downloads Build Status LICENSE

Markdown parser, simplicity and extensibility. Fork of marked and marked-ts.

Features

  • Awesome: ES6, TypeScript, Rollup, Jest...
  • Extensible: Add your own extensions
  • Fast: Low-level compiler for parsing markdown without caching or blocking for long periods of time
  • Lightweight: It's 10kb of minified and gzipped

Install

yarn add smarkdown
# or
npm install smarkdown

browser (CDN): jsDelivr | unpkg

Usage

Import the library as a module:

const Smarkdown = require('smarkdown');

Or import the library with a script tag:

<script src="https://cdn.jsdelivr.net/npm/smarkdown/dist/smarkdown.min.js"></script>

Example:

const str = 'I am using **Smarkdown**.';

console.log(Smarkdown.parse(str));
// <p>I am using <strong>Smarkdown</strong>.</p>

console.log(Smarkdown.parse(str, { nop: true }));
// I am using <strong>Smarkdown</strong>.

More

Comparison

Smarkdown Marked markdown-it
Version npm npm npm
Minified & Gzipped gzip size gzip size gzip size

License

Anti 996