mirror of
https://github.com/ivabus/www
synced 2024-11-10 05:25:14 +03:00
Merge pull request #290 from teaxyz/fetch-all-repos
Contributors section includes all repos
This commit is contained in:
commit
eeae257c22
|
@ -738,11 +738,13 @@
|
|||
|
||||
var contributorsList = $("#contributors-list");
|
||||
|
||||
$.getJSON("https://api.github.com/repos/teaxyz/cli/contributors", function(cliContributors) {
|
||||
$.getJSON("https://api.github.com/repos/teaxyz/pantry.extra/contributors", function(extraContributors) {
|
||||
var allContributors = cliContributors.concat(extraContributors);
|
||||
var uniqueContributors = {};
|
||||
$.each(allContributors, function(i, contributor) {
|
||||
var repos = ["cli", "pantry.extra", "pantry.zero", "white-paper", "setup", "brewkit", "www", "kettle", "demos"];
|
||||
|
||||
var uniqueContributors = {};
|
||||
|
||||
$.each(repos, function(i, repo) {
|
||||
$.getJSON("https://api.github.com/repos/teaxyz/" + repo + "/contributors", function(contributors) {
|
||||
$.each(contributors, function(j, contributor) {
|
||||
if (!(contributor.id in uniqueContributors)) {
|
||||
uniqueContributors[contributor.id] = true;
|
||||
contributorsList.append("<div class='col-3 col-sm-3 col-md-3 col-lg-1 col-xl-1 ps-0'>" + "<a href='" + contributor.html_url + "' target='_blank'><img class='con-img mb-3' src='" + contributor.avatar_url + "'></a>" + "<p class='small' style='hyphens:auto;'>" + contributor.login + "</p>" + "</div>");
|
||||
|
|
Loading…
Reference in a new issue