lib/analyzers/npm/index.js
function getCredits(projectPath, credits) {
	credits = credits || [];

	const depPath = path.join(projectPath, 'node_modules');

	globby.sync(`${depPath}/**/package.json`)
		.forEach(packagePath => {
			getNpmCredits(packagePath, credits);
		});

	return credits;
}
function getCredits(projectPath, credits) {
	credits = credits || [];

	const depPath = path.join(projectPath, 'node_modules');

	globby.sync(`${depPath}/**/package.json`)
		.forEach(packagePath => {
			getNpmCredits(packagePath, credits);
		});

	return credits;
}
function getCredits ( projectPath , credits ) { credits = credits || [ ] ; const depPath = path . join ( projectPath , 'node_modules' ) ; globby . sync ( ` ${ depPath } ` ) . forEach ( packagePath => { getNpmCredits ( packagePath , credits ) ; } ) ; return credits ; }
Read project root and evaluate dependency credits for node modules

@param  {String} projectPath      absolute path to project root
@param  {Array|undefined} credits list of credits
@param  {Array|undefined} seen    list of already iterated packages

@return {Array}                   list of credits
Read project root and evaluate dependency credits for node modules