npms-info
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

npms-info

an API Wrapper for NPMs

Documents

Work in progress...

Examples

  • Fetch Package Information
// ESM
import npmsinfo from "npms-info"

// CommonJS
const npmsinfo = require("npms-info")

npmsinfo('PACKAGE-NAME')
.then(result => {
    console.log(result);
})
.catch(console.error)
  • Fetch Package with a specific version
// ESM
import npmsinfo from "npms-info"

// CommonJS
const npmsinfo = require("npms-info")

npmsinfo('PACKAGE-NAME', 'PACKGE-VERSION')
.then(result => {
    console.log(result);
})
.catch(console.error)
  • Get other packages of the maintainer
// ESM
import npmsinfo from "npms-info"

// CommonJS
const npmsinfo = require("npms-info")

npmsinfo('PACKAGE-NAME')
.then(result => {
    result.maintainers[0].fetchPackages()
    .then(userPackages => {
        // Enjoy the data.
    })
})
.catch(console.error)

Package Sidebar

Install

npm i npms-info

Weekly Downloads

2

Version

1.0.0

License

ISC

Unpacked Size

20.3 kB

Total Files

24

Last publish

Collaborators

  • boycode