-
-
Notifications
You must be signed in to change notification settings - Fork 4
Add types #5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add types #5
Conversation
Good question.
This isn't advise, so much as offering an alternative for developers who don't want the lint checks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @Murderlon this looks pretty good!
Would it be possible to use dtslint
to get the additional lint checks provided?
And could a test case be added verifying the util can be used in a Unified plugin/tranform? (similar to https://github.com/syntax-tree/mdast-util-toc/blob/94cbac8b65c16209537d863f092642cb6a45bcf4/types/mdast-util-toc-tests.ts#L55-L64)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks @Murderlon! 🙇♂️
/cc @Rokt33r |
I added a unified plugin example. I’m a bit confused on what it tests in this context. To me, it seems I don’t explicitly assert anything? |
Mainly it ensures that |
Released in 2.0.0! |
Closes #4
Wanted to know the process of adding types to an existing lib so here we are. I followed Microsoft's advice on using
tsd
instead ofdtslint
. Am I missing a reasondtslint
is always used even for simple tests?