-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6707a59
commit 90dd485
Showing
1 changed file
with
40 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,52 @@ | ||
react-jazzicon | ||
============== | ||
[![NPM version][npm-image]][npm-url] [![dependencies Status][david-dep-image]][david-dep-url] [![devDependencies Status][david-devDep-image]][david-devDep-url] | ||
|
||
# demo page | ||
This is a react component for [Dan Finlay's](https://github.com/danfinlay) | ||
[jazzicon](https://github.com/danfinlay/jazzicon). | ||
|
||
# usage | ||
|
||
```js | ||
import Jazzicon from 'react-jazzicon' | ||
|
||
export default class App extends React.Component { | ||
|
||
… | ||
|
||
render() { | ||
return ( | ||
<Jazzicon diameter={100} seed={Math.random(100).toString()} /> | ||
) | ||
} | ||
} | ||
``` | ||
|
||
# setup | ||
|
||
```sh | ||
$ https://github.com/marcusmolchany/react-jazzicon | ||
$ cd react-jazzicon | ||
$ yarn # or npm i | ||
``` | ||
|
||
## demo page | ||
|
||
the demo page is on the `gh-pages` branch in the `demo` folder. | ||
|
||
```sh | ||
# first install dependencies in the top level package | ||
$ npm i # or yarn | ||
$ yarn # or npm i | ||
|
||
# then checkout the gh-pages branch and install dependencies in the "demo" folder | ||
$ git checkout gh-pages | ||
$ cd demo && npm i # or yarn | ||
$ npm run start # or yarn start | ||
$ cd demo && yarn # or npm i | ||
$ yarn start # or npm run start | ||
``` | ||
|
||
[david-dep-image]: https://david-dm.org/marcusmolchany/react-jazzicon/status.svg | ||
[david-dep-url]: https://david-dm.org/marcusmolchany/react-jazzicon | ||
[david-devDep-image]: https://david-dm.org/marcusmolchany/react-jazzicon/dev-status.svg | ||
[david-devDep-url]: https://david-dm.org/marcusmolchany/react-jazzicon?type=dev | ||
[npm-image]: https://badge.fury.io/js/react-jazzicon.svg | ||
[npm-url]: https://npmjs.org/package/react-jazzicon |