Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parse Detail of Pinned Repositiories #78

Open
4 tasks
nelsonic opened this issue Jun 17, 2017 · 1 comment
Open
4 tasks

Parse Detail of Pinned Repositiories #78

nelsonic opened this issue Jun 17, 2017 · 1 comment

Comments

@nelsonic
Copy link
Owner

e.g:
image

So far we've got the URL of the pinned repo. we would also like to get:

  • stars (count)
  • lang (language if specified)
  • desc (description)
  • forks (count)
@Rob-Rychs
Copy link

Rob-Rychs commented Dec 4, 2017

Was looking at this earlier today,

// Pinned Repos
  data.pinned = [];
  var p = '.pinned-repo-item-content:nth-of-type(' // is this being used?
  var urls = $('.pinned-repo-item-content a.text-bold')
  var language_color = $('.repo-language-color')
  for (var i = 0; i < $('.pinned-repo-item-content').length; i++) {
    var pin = {
      url: urls[i].attribs.href,
      // Want More? see: https://github.com/nelsonic/github-scraper/issues/78
      language: language_color[i].css('backgroundColor'),
      // stars: ,
      // desc: ,
      // forks: 
    }
    data.pinned.push(pin);
  }

Figured if I could get the backgroundColor I could use this to get the language without having to even think about selecting the lang while dealing with this kind of garbage whitespace...

            JavaScript
        

image

But I'm having trouble getting the backgroundColor from $('.repo-language-color')...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants