How can I calculate user's CPU usage percentage from React website?

Viewed 214

I'm trying to get the user's CPU usage percentage from a React application. I've tried using os.loadavg() (documentation here), but this gives the load average, which is something else I believe. I've also tried using this program from someone in GitHub (here), but it's very inconsistent and depending on where I run it, the values are different. For instance, if I run it on an IDE online, I get a certain value, but on another IDE its different as well.

What I want is to get the actual user's average, not my website's usage or anything of the sort. The tool I'm creating is supposed to give information to the user about their own CPU usage.

I'd appreciate if you could help, thanks.

0 Answers
Related