Skip to content
This repository has been archived by the owner on Mar 7, 2023. It is now read-only.

Add type definitions #66

Merged
merged 2 commits into from
Jul 23, 2018
Merged

Add type definitions #66

merged 2 commits into from
Jul 23, 2018

Conversation

thegecko
Copy link
Contributor

Resolves #65

Tested in a TypeScript project using both callback and promise forms of find as well as plug/unplug events.

Events aren't typed, so accept any event name, but should suffice in most cases.

@MadLittleMods
Copy link
Owner

Is the types/ directory standard practice vs just putting it alongside the file? (examples?)

@thegecko
Copy link
Contributor Author

There isn't really a convention, I personally prefer to keep the types separate.
The TypeScript docs has you put the types next to the JS files. I've updated the PR to do that instead.

@MadLittleMods MadLittleMods merged commit 7f83cdf into MadLittleMods:master Jul 23, 2018
@MadLittleMods
Copy link
Owner

Thanks for the contribution @thegecko

This is now part of 3.2.0. I'm waiting to publish to npm until the prebuild binaries are available, https://github.com/MadLittleMods/node-usb-detection/releases/tag/v3.2.0

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants