npm-user
TypeScript icon, indicating that this package has built-in type declarations

6.1.1 • Public • Published

npm-user

Get user info of an npm user

Since npm has no API for this, we are forced to scrape the profile page.

Use the faster npm-email package if you only need the email.

Install

npm install npm-user

Usage

import npmUser from 'npm-user';

console.log(await npmUser('sindresorhus'));
/*
{
	name: 'Sindre Sorhus',
	avatar: 'https://www.npmjs.com/npm-avatar/…',
	email: 'sindresorhus@gmail.com',
	github: 'sindresorhus',
	twitter: 'sindresorhus'
}
*/

The values will be undefined if they're not set in the npm profile.

Related

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 6.1.1
    41
    • latest

Version History

Package Sidebar

Install

npm i npm-user

Weekly Downloads

85

Version

6.1.1

License

MIT

Unpacked Size

4.95 kB

Total Files

5

Last publish

Collaborators

  • sindresorhus