From 1feaa398265f76ccf565424d8a4faedcfd5551b8 Mon Sep 17 00:00:00 2001 From: Martin Fischer Date: Fri, 3 Jan 2025 19:55:24 +0100 Subject: [PATCH] Export Event type This enables users to refer to the EventParser as `Iterable` which is much more readable than `ReturnType`. --- src/block.ts | 2 +- src/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/block.ts b/src/block.ts index 3acbd67..dd3084a 100644 --- a/src/block.ts +++ b/src/block.ts @@ -1119,4 +1119,4 @@ const parseEvents = function(input : string, options : Options = {}) { return new EventParser(input, options); } -export { parseEvents } +export { parseEvents, type Event } diff --git a/src/index.ts b/src/index.ts index f448342..faadb8a 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,5 +1,5 @@ export { parse, renderAST } from "./parse"; -export { parseEvents } from "./block"; +export { parseEvents, type Event } from "./block"; export { renderHTML, HTMLRenderer } from "./html"; export { applyFilter } from "./filter"; export { fromPandoc, toPandoc } from "./pandoc";