nodejs.org icon indicating copy to clipboard operation
nodejs.org copied to clipboard

fix: Wrong bitness information

Open canerakdas opened this issue 11 months ago • 8 comments

Description

If we cannot get the user's bitness information from the userAgent if getHighEntropyValues is not supported, the default is x86.

We act as if we are using the architecture, but since the x86 version is not officially distributed for Linux and Mac, users are directed to the wrong links.

This PR aims to create an alternative source to getHighEntropyValues by adding more to the conditions we check in userAgent.

Also, should we do something in the UI for versions that do not have an x86 version? (Maybe disabling the button?) cc @nodejs/nodejs-website

Validation

It would be better to test it on as many operating systems as possible in preview 👀

Related Issues

Fixes #6360

Check List

  • [x] I have read the Contributing Guidelines and made commit messages that follow the guideline.
  • [x] I have run npx turbo format to ensure the code follows the style guide.
  • [x] I have run npx turbo test to check if all tests are passing.
  • [x] I have run npx turbo build to check if the website builds without errors.
  • [x] I've covered new added functionality with unit tests if necessary.

canerakdas avatar Mar 19 '24 21:03 canerakdas