1.0.14 • Published 3 years ago

react-native-identicon v1.0.14

Weekly downloads
2
License
ISC
Repository
github
Last release
3 years ago

react-native-identicon

The core of the project is a clone of the repository: node-identicon. I only made the library wrapper as a component in addition to using other alternate libraries such as: react-native-crypto and react-native-canvas

Install

# TypeScript
npm install -g typescript
# Peer dependencies
npm install react-native-webview
npm install @types/node
npm install react-native-randombytes
npm install tradle/rn-nodeify --save-dev
# Hack some node modules. I recommend that you then put this inside the "postinstall" of the package.json
./node_modules/.bin/rn-nodeify --install 'stream,crypto,events,process' --hack

Running rn-nodeify generates a shim.js file in the root of the project. Import this file into the index.js:

/**
 * @format
 */
import './shim' // ==> Import Here
import {AppRegistry} from 'react-native';
import App from './App';
import {name as appName} from './app.json';

AppRegistry.registerComponent(appName, () => App);
# Install component
npm install react-native-identicon
npx pod-install ios

Usage

import React from 'react';
import Identicon from 'react-native-identicon';

const App = () => {
    return (
        <Identicon value={'test'} />
    )
}

Optional parameters

  • style: object with container's styles
  • size: default 45
1.0.14

3 years ago

1.0.13

3 years ago

1.0.12

3 years ago

1.0.11

3 years ago

1.0.10

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago