JSPM

@mdit-kdu/types

1.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 4
  • Score
    100M100P100Q18789F
  • License MIT

Shared types definition of mdit-kdu

Package Exports

  • @mdit-kdu/types

Readme

@mdit-kdu/types

Shared types definition of mdit-kdu.

Install

npm i @mdit-kdu/types

Usage

Add more properties to env via TypeScript module augmentation:

declare module '@mdit-kdu/types' {
  interface MarkdownItEnv {
    foo?: string[];
  }
}
import MarkdownIt from 'markdown-it';
import type { MarkdownItEnv } from '@mdit-kdu/types';

const md = MarkdownIt({ html: true });
const env: MarkdownItEnv = {};
const rendered = md.render('raw markdown text', env);