faisalman / ua-parser-js

UAParser.js - The Essential Tool for User-Agent Detection in JavaScript & Web Development.
https://uaparser.dev/
GNU Affero General Public License v3.0
8.85k stars 1.18k forks source link

Got Could not find a declaration file for module 'ua-parser-js'. #703

Closed yujonglee closed 5 months ago

yujonglee commented 5 months ago

Library version 2.0.0-beta.1

Describe the bug Got Could not find a declaration file for module 'ua-parser-js'.

To Reproduce Download 2.0.0-beta.1, and import it in typescript file.

Expected behavior No error

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Additional context

Could not find a declaration file for module 'ua-parser-js'. <PROJECT>/node_modules/ua-parser-js/src/main/ua-parser.mjs' implicitly has an 'any' type.
  There are types at '<PROJECT>/node_modules/ua-parser-js/src/main/ua-parser.d.ts', but this result could not be resolved when respecting package.json "exports". The 'ua-parser-js' library may need to update its package.json or typings.ts(7016)