Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

24 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-native-easy-rating

npm package npm Gitter

A React Native component for rating view. Compatible with both iOS and Android.

####Tested with react-native 0.27.1

Installation

npm install react-native-easy-rating --save

Usage

Props

Prop Type Description Required Default
rating number Set initial rating No 0
max number Set maximum of rating No 5
iconWidth number Set width of icon No 36
iconHeight number Set height of icon No 36
iconSelected image Set image of selected icon No
iconUnselected image Set image of unselected icon No
onRate function(rating) Trigger when rating changes Yes
editable boolean Ability to change rating by tap No Yes

Example

import  Rating from 'react-native-easy-rating'
...
<Rating
    rating={1}
    max={5}
    iconWidth={24}
    iconHeight={24}
    iconSelected={require('../../img/icon_star_selected.png')}
    iconUnselected={require('../../img/icon_star_unselected.png')}
    onRate={(rating) => this.setState({rating: rating})}/>

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages