markdown parser with css style

GitHub version npm version

What's flav-md?

Flav-md is an open source library for parsing markdown docs to html with css. When parsing md files with flav-md, html tags in genrated documents have html element class for flav-md; flav-h1, flav-text, etc. Only you have to do is write markdown docs and CSS file for generated htmls.

How to install?

You can install flav-md via npm with

$ npm install flav-md

How to use?

You can use flav-md in Node.js (ES5), ES6, and alos, TypeScript.

Node.js (ES5)

const flavmd = require('flav-md');
const result = flavmd
  .createFlavMd()
  .readMdText('# hogehoge')
  .readCssText('.flav-md-h1 {color: red;}')
  .build();

ES6 and TypeScript

import { createFlavMd } from 'flav-md';

const result = createFlavMd()
  .readMdText('# hogehoge')
  .readCssText('.flav-md-h1 {color: red;}')
  .build();

More info

You can show & contribute flav-md in GitHub.