Skip to content

GitHub participation graphs built with a canvas element and sorcery

Notifications You must be signed in to change notification settings

applideveloper/Gitgraph

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

87 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dirt simple GitHub participation graphs built with a <canvas> element and sorcery.

##Usage

  1. Paste right before your page's closing </body> tag
<script src="Gitgraph.min.js"></script>
  1. From within a script tag or a JS file
    var graph = new Gitgraph({ 
        user        : 'nex3',                // any github username
        repo        : 'sass',                // name of repo
        domNode     : document.body,         // (optional) DOM node to attach to 
        width       : 800,                   // (optional) graph width
        height      : 300,                   // (optional) graph height
        allColor    : "rgb(202, 202, 202)",  // (optional) color of user's participation
        userColor   : "rgb(51, 102, 153)",   // (optional) color of total participation
        background  : "white",               // (optional) background styles
        showName    : true                   // (optional) show or hide name of user / repo
    });

##Limitations GitHub hasn't exposed participation data via the api yet, but plans to. Until then, requests funnel through a simple proxy via my vps.

##Contributing Gitgraph uses Grunt for file linting and uglification. To start contributing, first make sure node is installed. Then:

git clone https://github.com/bitpshr/Gitgraph.git
cd Gitgraph
git submodule update --recursive --init
npm install
# hack on Gitgraph.js, run `grunt`, view demo/index.html

##License WTFPL

About

GitHub participation graphs built with a canvas element and sorcery

Resources

Stars

Watchers

Forks

Packages

No packages published