Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
S

snarkdown

> 编程语言
Open source

:smirk_cat: A snarky 1kb Markdown parser written in JavaScript

2.4K stars0 likes3 views
WebsiteGitHub

About

:smirk_cat: A snarky 1kb Markdown parser written in JavaScript

Snarkdown

Snarkdown is a dead simple 1kb Markdown parser.

It's designed to be as minimal as possible, for constrained use-cases where a full Markdown parser would be inappropriate.

Features

  • Fast: since it's basically one regex and a huge if statement
  • Tiny: it's 1kb of gzipped ES3
  • Simple: pass a Markdown string, get back an HTML string

Note: Tables are not yet supported. If you love impossible to read regular expressions, submit a PR!

Note on XSS: Snarkdown doesn't sanitize HTML, since its primary target usage doesn't require it.

Demos & Examples

  • ⚛️ Snarky - markdown editor built with Preact & Snarkdown
  • ✏️ Simple Markdown Editor

Usage

Snarkdown exports a single function, which parses a string of Markdown and returns a String of HTML. Couldn't be simpler.

The snarkdown module is available in every module format you'd ever need: ES Modules, CommonJS, UMD...

javascript
import snarkdown from 'snarkdown';

let md = '_this_ is **easy** to `use`.';
let html = snarkdown(md);
console.log(html);
// <em>this</em> is <strong>easy</strong> to <code>use</code>.

Add-ons and Libraries

  • For Webpack users, snarkdown-loader renders markdown files to html.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

JavaScriptjavascriptmarkdownparser

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言