react-github-activity-feed
v3.0.3
Published
Turn-key Github activity feed React component. Great for portfolio sites of sporadic open-source developers.
Downloads
8
Maintainers
Readme
react-github-activity-feed
Turn-key Github activity feed React component. Great for portfolio sites of sporadic open-source developers.
Storybook Demo & Docs available here
Most of the credit goes to @caseyscarborough for his work on github-activity-feed
Install
yarn add react-github-activity-feed
# or
npm i --save react-github-activity-feed
QuickStart
import { GithubActivityFeed } from "react-github-activity-feed";
import "react-github-activity-feed/light.css"
// or "react-github-activity-feed/dark.css"
const MyGithubActivity = () => (
<GithubActivityFeed
user="callumjhays"
repo="react-github-activity-feed"
limit={20}
/>
);
Requires react >= v16.8
for functional components & hooks. If you need older version support please post a quick github issue and I'll get around to it.
Why
Like react-github-activity, I was inspired by github-activity-feed but wanted a simpler way to include it in a react app.
I also wanted to publish my first npm react component package and try out Rollup and hosting storybook demos on github.io.
Unlike react-github-activity, rather than starting from scratch (maybe because he wanted support for private events), I just "react-ified" the original library. I also wanted to try avoiding littering the global JS namespace, so I manually copied and edited the source-code.
Limitations
- Limited by github REST api request rate (currently 60/hour). After this, the component will display an error.
- Very bloated (added 160kB) to my next.js production build. Unsure why this