uap-ref-impl icon indicating copy to clipboard operation
uap-ref-impl copied to clipboard

is it npm ua-parser?

Open zowers opened this issue 10 years ago • 10 comments

is this the source of npm's ua-parser package? https://www.npmjs.com/package/ua-parser

and why is the version https://github.com/ua-parser/uap-ref-impl/blob/master/package.json#L5 is lower then https://github.com/tobie/ua-parser/blob/master/package.json#L5?

zowers avatar Apr 10 '15 09:04 zowers

I agree, since the split of tobie/ua-parser to the uaparser project space, things became rather confusing for JavaScript users.

From what I understand:

  • ua-parser/uap-core now wraps the up-to-date regexes.yaml, which contains the core definitions, shared by all language implementations.
  • tobie/ua-parser is the legacy repository, which holds its own outdated regexes.yaml. Apparently, this is what is currently published as ua-parser on npm.
  • ua-parser/uap-ref-impl is supposed to be the official JavaScript reference implementation, as stated here. It sounds like a replacement for the deprecated tobie/ua-parser, but it is not what happened yet (no documentation, no tests, low usage on npm, ...).

Any clarification is welcomed about this :smiley:. I'm particularly interested on how JavaScript users are supposed to work with the up-to-date regexes.yaml now.

connesc avatar Apr 16 '15 16:04 connesc

imo "JavaScript reference implementation" means something that is only for reference purposes, not for production use.

zowers avatar Apr 17 '15 08:04 zowers

:+1: this is rather confusing. There's now even a third npm package: https://www.npmjs.com/package/node-uap

josip avatar May 05 '15 13:05 josip

I will end by using the useragent package, which is widely used, and internally fetches the up-to-date regexes.yaml from ua-parser/uap-core.

connesc avatar May 22 '15 10:05 connesc

so confusing, took me like 5 minutes to find this cc @tobie

vladikoff avatar Jun 02 '15 22:06 vladikoff

Unfortunately, I don't really have the time to fix things atm. Maybe later this year?

tobie avatar Jun 02 '15 23:06 tobie

Hi. Is there any update on this issue?

vcarel avatar Feb 01 '16 12:02 vcarel

Unfortunately no. Would love to clean this mess up if someone was willing to sponsor the work. Can't afford the time away from client work otherwise. :(

tobie avatar Feb 01 '16 12:02 tobie

@josip as a node-uap packager, I would love to see the ua-parser/uap-core package published to npm registry. That way I could be using ua-parser/uap-ref-impl directly (and contributing to it instead of rolling my wrap-up)

fedot avatar Feb 16 '16 11:02 fedot

Spent time trying to figure out this as well 😄 very confusing...

In the end I decided to go with useragent, it works great!

LinusU avatar Oct 23 '17 14:10 LinusU