decoupled-data-markdown
TypeScript icon, indicating that this package has built-in type declarations

1.1.0 • Public • Published

decoupled-data-markdown

Markdown with YAML data-source for decoupled and general usage.

Parses Markdown into HTML and supports full-featured YAML frontmatter.

Features

  • load markdown-docs by slug
  • parse markdown with Showdown
  • parse YAML-frontmatter with YAML
  • custom !!md YAML-tag for additional markdown fields in front-matter

Use-cases

  • simple document-based websites or blogs
  • metadata support for posts
  • complex data-structures for enriching pages
  • use frontmatter for complex page-builder structures

Usage

In config/SITE/router.js use:

import { decoupledMarkdownHandler } from 'decoupled-data-markdown';

module.exports.router = {
    routes: [
        {
            method: 'GET',
            route: '(.*)',
            handler: decoupledMarkdownHandler,
        },
    ]
};

Readme

Keywords

none

Package Sidebar

Install

npm i decoupled-data-markdown

Weekly Downloads

1

Version

1.1.0

License

MIT

Unpacked Size

9.26 kB

Total Files

17

Last publish

Collaborators

  • oerdmann