GithubHelp home page GithubHelp logo

fengyiyi / jquery-github Goto Github PK

View Code? Open in Web Editor NEW

This project forked from zenorocha/jquery-github

0.0 1.0 0.0 336 KB

A jQuery plugin to display your Github Repositories

Home Page: http://zenorocha.github.io/jquery-github/

jquery-github's Introduction

jQuery Github Build Status

Github Repo Demonstration

Usage

Create an attribute called data-repo:

<div data-repo="jquery-boilerplate/boilerplate"></div>

Include jQuery:

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>

Include plugin's CSS and JS:

<link rel="stylesheet" href="assets/base.css">
<script src="jquery.github.min.js"></script>

Call the plugin:

$("[data-repo]").github();

And that's it \o/

Check full example's source code.

Options

Here's a list of available settings.

$("[data-repo]").github({
	iconStars:  true,
	iconForks:  true,
	iconIssues: false
});

iconStars

Type: Boolean Default: true

Display the number of stars in a repository.

iconForks

Type: Boolean Default: true

Display the number of forks in a repository.

iconIssues

Type: Boolean Default: false

Display the number of issues in a repository.

Structure

The basic structure of the project is given in the following way:

.
|-- assets/
|-- demo/
|   |-- index.html
|-- dist/
|   |-- jquery.boilerplate.js
|   |-- jquery.boilerplate.min.js
|-- src/
|   |-- jquery.boilerplate.coffee
|   |-- jquery.boilerplate.js
|-- .editorconfig
|-- .gitignore
|-- .jshintrc
|-- .travis.yml
|-- github.jquery.json
|-- Gruntfile.js
`-- package.json

assets/

Contains CSS and Font files to create that lovely Github box.

demo/

Contains a simple HTML file to demonstrate the plugin.

dist/

This is where the generated files are stored once Grunt runs JSHint and other stuff.

src/

Contains the files responsible for the plugin.

.editorconfig

This file is for unifying the coding style for different editors and IDEs.

Check editorconfig.org if you haven't heard about this project yet.

.gitignore

List of files that we don't want Git to track.

Check this Git Ignoring Files Guide for more details.

.jshintrc

List of rules used by JSHint to detect errors and potential problems in JavaScript.

Check jshint.com if you haven't heard about this project yet.

.travis.yml

Definitions for continous integration using Travis.

Check travis-ci.org if you haven't heard about this project yet.

github.jquery.json

Package manifest file used to publish plugins in jQuery Plugin Registry.

Check this Package Manifest Guide for more details.

Gruntfile.js

Contains all automated tasks using Grunt.

Check gruntjs.com if you haven't heard about this project yet.

package.json

Specify all dependencies loaded via Node.JS.

Check NPM for more details.

Showcase

Have you used this plugin in your project?

Let me know! Send a tweet or pull request and I'll add it here :)

Forks

Prefer a non-jquery version with pure JavaScript?

No problem, @ricardobeat already did one. Check his fork!

Contributing

Check CONTRIBUTING.md

History

Check HISTORY.md

Credits

Built on top of jQuery Boilerplate

License

MIT License

jquery-github's People

Contributors

djalmaaraujo avatar douglasmiranda avatar obetomuniz avatar zenorocha avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.