Closed th3f0r3ign3r closed 1 year ago
UAParser
is exposed as a named export rather than a default, maybe you miss the {}
?
import { UAParser } from 'ua-parser-js'
UAParser
is exposed as a named export rather than a default, maybe you miss the{}
?import { UAParser } from 'ua-parser-js'
OK let me try !🤞🏾
UAParser
is exposed as a named export rather than a default, maybe you miss the{}
?import { UAParser } from 'ua-parser-js'
Thanks it work !!
Tthe bug I just trying to parse the userAgent of users calling an API based on NestJS and after creating an instance of UAParser and the userAgent i get this error when calling the function
TypeError: ua_parser_js_1.default is not a constructor
After installing
nestjs
app.controller.ts
Result
OS: MacOs 13.5.2