Skip to content

faeghe-hajiabadi/react-github-badge

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-github-badge

Inspired by vue-github-badge

NPM version NPM downloads

Demo

see here

Install

yarn add @sinchang/react-github-badge

Usage

import GithubBadge from '@sinchang/react-github-badge'

...

render () {
  return (
    <GithubBadge
      url='sinchang/react-github-badge'
    />
  )
}

API

Props

slug

Type: string
Required: true

GitHub slug (owner/repo)

width/height

Type: number
Default: 36

width/height of svg icon

fill

Type: string
Default: black

The fill color of svg icon, you can set it to currentColor to inherit from parent element.

Contributing

  1. Fork it!
  2. Create your feature branch: git checkout -b my-new-feature
  3. Commit your changes: git commit -am 'Add some feature'
  4. Push to the branch: git push origin my-new-feature
  5. Submit a pull request :D

Author

react-github-badge © sinchang, Released under the MIT License.
Authored and maintained by sinchang with help from contributors (list).

sinchang.me · GitHub @sinchang · Twitter @sinchangwen

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 61.9%
  • HTML 27.8%
  • CSS 10.3%