faisalman / ua-parser-js

"Unmask Your Traffic" - UAParser.js: The Essential Web Development Tool for User-Agent Detection
https://uaparser.dev/
GNU Affero General Public License v3.0
9.28k stars 1.19k forks source link

`headers` type incorrect #767

Open cduff opened 19 hours ago

cduff commented 19 hours ago

Library version 2.0.0

Describe the bug UAParser(req.headers) results in TypeScript compile error.

To Reproduce Try following the withClientHints example from https://docs.uaparser.dev/intro/quick-start/using-node-js.html.

Expected behavior Compiling code.

Screenshots image

Additional context