Github Repo Widgets 0.1.6

Github Repo Widgets is a MooTools plugin that allows you to fetch information regarding a Github repository using a JSONP request, and builds an HTML widget for you.



Details

Author
re5et
Current version
0.1.6
GitHub
re5et/github-repo-widgets
Downloads
9110
Category
Widgets
Tags
Report
GitHub Issues

Releases


Dependencies

  • _self_/_current_:
    • GithubRepoWidget
    • more/ 1.3.0.1rc1: [Element.Position]
    • core/1.3: [Class.Extras, Element.Event, Element.Style, Selectors]
    • more/1.3.0.1rc1: [Request.JSONP]

How to use

You can use GithubRepoWidget to create a widget by doing the following:

var myRepoWidget = new GithubRepoWidget('mootools', 'mootools-more');
myRepoWidget.addEvent('complete', function(response, widget){
    $('myElement').grab(widget);
});

or you can supply an element to inject into and have the complete event handled for you:

var myRepoWidget = new GithubRepoWidget('re5et', '.dotfiles', {
    'injectInto': $('myElement')
});

You can also use hoverCards, which will automatically find github repo links and attach hovercards to them, by running:

GithubRepoWidget.hovercards()

Discuss

A note on comments here: These comments are moderated. No comments will show up until they are approved. Comments that are not productive (i.e. inflammatory, rude, etc) will not be approved.

Found a bug in this plugin? Please report it this repository's Github Issues.

blog comments powered by Disqus