Skip to content

Conversation

@0b5vr
Copy link
Contributor

@0b5vr 0b5vr commented Dec 9, 2025

Proposed Changes

I exposed missing NumberListNode from the index.ts exports.

Context

I'm making a library called scrapbox-parser-to-markdown that takes the output of scrapbox-parser and converts it to markdown. In this library, I need the NumberListNode type to type things correctly. Since other nodes are already exposed from index.ts, I think it's more natural to expose NumberListNode as well.

See how I use NumberListNode in my codebase: https://github.com/0b5vr/scrapbox-parser-to-markdown/blob/bc7f7a9511c68f19aa5fef5e464cc1042912f57f/src/nodeToMarkdown.ts#L77

Workaround

type NumberListNode = Extract<Node, { type: 'numberList' }>; would work.

Context: I'm making a library called scrapbox-parser-to-markdown that takes the output of scrapbox-parser and converts it to markdown.
In this library, I need the `NumberListNode` type to type things correctly.
Since other nodes are already exposed from `index.ts`, I think it's more natural to expose `NumberListNode` as well.

See how I use `NumberListNode` in my codebase: https://github.com/0b5vr/scrapbox-parser-to-markdown/blob/bc7f7a9511c68f19aa5fef5e464cc1042912f57f/src/nodeToMarkdown.ts#L77

Workaround: `type NumberListNode = Extract<Node, { type: 'numberList' }>;` would work.
Copy link
Owner

@progfay progfay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution, LGTM!

@progfay progfay merged commit 0597b5b into progfay:main Dec 10, 2025
2 checks passed
This was referenced Dec 10, 2025
@progfay
Copy link
Owner

progfay commented Dec 10, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants