Get a list of npm packages with keywords
npm install npm-keyword
import {npmKeyword, npmKeywordNames, npmKeywordCount} from 'npm-keyword';
console.log(await npmKeyword('gulpplugin'));
//=> [{name: 'gulp-autoprefixer', description: '…'}, …]
console.log(await npmKeywordNames('gulpplugin'));
//=> ['gulp-autoprefixer', …]
console.log(await npmKeywordCount('gulpplugin'));
//=> 3457
The list of packages will contain a maximum of 250 packages matching the keywords. This limitation is caused by the npm registry API.
Returns a promise for a list of packages having the specified keyword in their package.json keywords
property.
Type: string | string[]
Example: ['string', 'camelcase']
One or more keywords. Only matches packages that have all the given keywords.
Type: object
Type: number
Default: 250
Limits the amount of results.
Returns a promise for a list of package names.
Type: string | string[]
Example: ['string', 'camelcase']
One or more keywords. Only matches packages that have all the given keywords.
Type: object
Type: number
Default: 250
Limits the amount of results.
Returns a promise for the count of packages.
Type: string | string[]
Example: ['string', 'camelcase']
One or more keywords. Only matches packages that have all the given keywords.
- package-json - Get the package.json of a package from the npm registry
- npm-user - Get user info of an npm user
- npm-email - Get the email of an npm user