diff --git a/index.d.ts b/index.d.ts new file mode 100644 index 0000000..a90b761 --- /dev/null +++ b/index.d.ts @@ -0,0 +1,6 @@ +declare module 'markdown-it-front-matter' { + import MarkdownIt from 'markdown-it/lib' + export type FrontMatterPluginOptions = (rawMeta: string) => void + const markdownItFrontMatter: MarkdownIt.PluginWithOptions + export = markdownItFrontMatter +} diff --git a/package.json b/package.json index 181a8d7..52b3cad 100644 --- a/package.json +++ b/package.json @@ -7,6 +7,7 @@ "url": "git://github.com/ParkSB/markdown-it-front-matter.git" }, "main": "index.js", + "types": "index.d.ts", "keywords": [ "markdown-it-plugin", "markdown-it", @@ -23,6 +24,7 @@ "license": "MIT", "devDependencies": { "markdown-it": "^10.0.0", + "@types/markdown-it": "^10.0.0", "mocha": "^7.0.1" }, "scripts": {