
Product
Introducing the Alert Details Page: A Better Way to Explore Alerts
Socket's new Alert Details page is designed to surface more context, with a clearer layout, reachability dependency chains, and structured review.
stringify-authors
Advanced tools
Converts an author object or array of author objects into an array of strings. Useful for adding authors, maintainers or contributors to documentation, package.json or a readme.
Converts an author object or array of author objects into an array of strings. Useful for adding authors, maintainers or contributors to documentation, package.json or a readme.
Install with npm
$ npm i stringify-authors --save
var authors = require('stringify-authors');
Given an array of author objects:
var authors = [{
name: 'Jon Schlinkert',
email: 'jon.schlinkert@sellside.com',
url: 'https://github.com/jonschlinkert'
}, {
name: 'Brian Woodward',
url: 'https://github.com/doowb',
email: 'brian.woodward@sellside.com'
}]
// default separator is ', '
stringify(authors, {sep: '\n'});
results in:
Jon Schlinkert <jon.schlinkert@sellside.com> (https://github.com/jonschlinkert)
Brian Woodward <brian.woodward@sellside.com> (https://github.com/doowb)
stringify(authors, {filter: 'name'});
//=> Jon Schlinkert, Brian Woodward
stringify(authors, {filter: '{name,url}', sep: '\n'});
// Jon Schlinkert (https://github.com/jonschlinkert)
// Brian Woodward (https://github.com/doowb)
author string into an object following npm conventions. | homepagename, email and url properties following npm conventions.… more | homepagename, email and url properties following… more | homepagename <email> (url). | homepageInstall dev dependencies:
$ npm i -d && npm test
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Jon Schlinkert
Copyright © 2015 Jon Schlinkert Released under the MIT license.
This file was generated by verb-cli on November 16, 2015.
FAQs
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.

Product
Socket's new Alert Details page is designed to surface more context, with a clearer layout, reachability dependency chains, and structured review.

Product
Campaign-level threat intelligence in Socket now shows when active supply chain attacks affect your repositories and packages.

Research
Malicious PyPI package sympy-dev targets SymPy users, a Python symbolic math library with 85 million monthly downloads.