usb.ids 2.20260610.0 → 2.20260626.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,74 @@
1
+ # usb.ids
2
+
3
+ USB registry data and the `usb-ids` command line tool.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install -g usb.ids
9
+ ```
10
+
11
+ ## CLI
12
+
13
+ ```bash
14
+ usb-ids fetch
15
+ usb-ids fetch --force
16
+ usb-ids fetch --force --interactive
17
+ usb-ids fetch --force --interactive --yes
18
+ usb-ids fetch --offline
19
+ usb-ids version
20
+ usb-ids version --json
21
+ usb-ids check
22
+ usb-ids check --json
23
+ usb-ids ui --port 3000
24
+ usb-ids help
25
+ ```
26
+
27
+ Stable exit codes:
28
+
29
+ - `0` success
30
+ - `2` usage error
31
+ - `3` data missing
32
+ - `4` network failure
33
+ - `5` parse failure
34
+ - `6` filesystem failure
35
+
36
+ `version --json` and `check --json` write machine-readable JSON to `stdout` only.
37
+
38
+ ## Data Files
39
+
40
+ The package includes the generated registry data:
41
+
42
+ - `usb.ids`
43
+ - `usb.ids.json`
44
+ - `usb.ids.version.json`
45
+ - `dist/data/usb.ids.min.json`
46
+ - `dist/data/usb.ids.compact.json`
47
+ - `dist/data/vendors.index.json`
48
+ - `dist/data/vendors/*.json`
49
+
50
+ ## SDK
51
+
52
+ Programmatic access is available as a secondary interface:
53
+
54
+ ```ts
55
+ import { getVendors, loadUsbData, searchInData } from "usb.ids";
56
+
57
+ const data = await loadUsbData();
58
+ const vendors = await getVendors();
59
+ const found = searchInData(data, "keyboard");
60
+ ```
61
+
62
+ Browser-safe subpath:
63
+
64
+ ```ts
65
+ import { filterVendors, searchInData } from "usb.ids/browser";
66
+ ```
67
+
68
+ ## Source
69
+
70
+ Repository: https://github.com/Drswith/usb.ids
71
+
72
+ ## License
73
+
74
+ MIT