Skip to content

Component type support for 'icon' prop and bugfix and update Readme #21

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ngxiaoyi
Copy link

@ngxiaoyi ngxiaoyi commented Apr 18, 2017

  1. Support component/react element type of 'icon' prop. Component type of icon prop type support #20 Now we can use react-native-vector-icons or other image component like this:
<ItemCell
  icon={<Icon name="ios-person" size={30} color="#4F8EF7" />}
>
  text here
</ItemCell>
  1. Remove children proptype check. "this.props.children" is a special prop of React: https://facebook.github.io/react/docs/jsx-in-depth.html#children-in-jsx , the children prop here won't work and will leads to an warning.

  2. update the doc

Tested on my local env, maybe need furthermore tests.

@alvaromb
Copy link
Collaborator

Hey! Looks great @ngxiaoyi!

Thanks.

@alvaromb alvaromb self-requested a review April 20, 2017 10:50
@alvaromb
Copy link
Collaborator

Looks good, will merge today.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants