Socket
Socket
Sign inDemoInstall

hardware-info

Package Overview
Dependencies
0
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    hardware-info

A lightweight way to get the hardware information.


Version published
Weekly downloads
1
decreased by-75%
Maintainers
1
Install size
2.91 kB
Created
Weekly downloads
 

Readme

Source

hardware-info

A lightweight way to get the hardware information.

Install

npm install hardware-info

Usage

import {getCpu, getRam, getOsArch} from 'hardware-info';

console.log(getCpu());
// => { threads: 16, model: 'Intel(R) Core(TM) i7-10700F CPU @ 2.90GHz', speed: 2904 }'

console.log(getRam());
//=> '{ total: '15.93 GB', free: '7.15 GB' }'

console.log(getNetInterfaces());
//=> '[{"name":"Ethernet 7","addresses":[{"path":"fe80::81aa:d714:a0f:90cf","internal":false},{"path":"192.168.56.1","internal":false}]'

console.log(getOsArch());
//=> '{"arch":"x64"}'

Unpacked Size

Less than 5 kB

Keywords

FAQs

Last updated on 13 Nov 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc