React GitHub Ribbons
Simple React Component to add GitHub Ribbon for your React Application.
Ref: https://github.blog/2008-12-19-github-ribbons/
Install
$ yarn add react-github-ribbons
Usage
;;;; ;
Ribbon color & position
We can change the color and position
// Default // Orange and left // White and right
Link parameters
The component will proxy a
tag properties.
And you can import the property types.
; ;
Commands
TSDX scaffolds your new library inside /src
, and also sets up a Parcel-based playground for it inside /example
.
The recommended workflow is to run TSDX in one terminal:
npm start # or yarn start
This builds to /dist
and runs the project in watch mode so any edits you save inside src
causes a rebuild to /dist
.
Then run the example inside another:
cd examplenpm i # or yarn to install dependencies npm start # or yarn start
The default example imports and live reloads whatever is in /dist
, so if you are seeing an out of date component, make sure TSDX is running in watch mode like we recommend above. No symlinking required, we use Parcel's aliasing.
To do a one-off build, use npm run build
or yarn build
.
To run tests, use npm test
or yarn test
.
Using the Playground
cd examplenpm i # or yarn to install dependencies npm start # or yarn start
The default example imports and live reloads whatever is in /dist
, so if you are seeing an out of date component, make sure TSDX is running in watch mode like we recommend above. No symlinking required!