Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/niborb/react-native-gravatar
React Native Gravatar component
https://github.com/niborb/react-native-gravatar
Last synced: 3 months ago
JSON representation
React Native Gravatar component
- Host: GitHub
- URL: https://github.com/niborb/react-native-gravatar
- Owner: niborb
- License: isc
- Created: 2016-03-20T12:34:05.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-04-03T18:27:46.000Z (over 6 years ago)
- Last Synced: 2024-08-05T06:58:37.072Z (3 months ago)
- Language: JavaScript
- Size: 6.84 KB
- Stars: 28
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-react-native - react-native-avatar-gravatar ★18 - React Native Gravatar component (Components / UI)
- awesome-reactnative-ui - react-native-gravatar - native-avatar-gravatar.svg?style=flat-square)| (Others)
- awesome-react-native - react-native-avatar-gravatar ★18 - React Native Gravatar component (Components / UI)
- awesome-reactnative-ui - react-native-gravatar - native-avatar-gravatar.svg?style=flat-square)| (Others)
- awesome-react-native - react-native-avatar-gravatar ★18 - React Native Gravatar component (Components / UI)
- awesome-react-native-ui - react-native-avatar-gravatar ★10 - React Native Gravatar component (Components / UI)
- awesome-react-native - react-native-avatar-gravatar ★18 - React Native Gravatar component (Components / UI)
README
# React Native Gravatar component
[![npm version](https://img.shields.io/npm/v/react-native-avatar-gravatar.svg?style=flat-square)](https://www.npmjs.com/package/react-native-avatar-gravatar)
[![npm downloads](https://img.shields.io/npm/dm/react-native-avatar-gravatar.svg?style=flat-square)](https://www.npmjs.com/package/react-native-avatar-gravatar)React Native Gravatar is a simple component that loads the avatar with an option to mask it with a circle, rounded or square shape.
- [Installation](#installation)
## Installation
`npm install react-native-avatar-gravatar`## Usage
```javascript
import Gravatar from 'react-native-avatar-gravatar';class Application extends Component {
render () {
return (
)
}
})
```## Properties
### Basic
| Prop | Default | Type | Description |
| :------------ |:---------------:| :---------------:| :-----|
| emailAddress | '' | `string` | Email address for gravatar, if not provided uses default image for gravatar |
| size | 60 | `number` | Size for the gravatar image |
| mask | 'circle' | `number` | Mask for the gravatar image. One of - 'circle', 'square', 'rounded' |
| defaultImage | 'retro' | `string` | default image if no email address. One of - '404', 'mm', 'identicon', 'monsterid', 'wavatar', 'retro', 'robohash', 'blank' |
| resizeMode | 'contain' | `string` | resizeMode for the gravatar image |