vovkasm / react-native-web-image

An image component for react-native with persistent disk and memory caching.
MIT License
146 stars 25 forks source link

Add onLoadEnd callback #5

Open jordanmkoncz opened 7 years ago

jordanmkoncz commented 7 years ago

Firstly thanks for the great library, I've been having issues with caching trying to use react-native's Image component and your component seems to be handling caching perfectly.

Would it be possible to add an onLoadEnd callback prop to <WebImage /> that is invoked when load either succeeds or fails? Essentially the same thing as onLoadEnd for react-native's Image component. I see that there is already an onError callback prop so I'm hoping that it wouldn't be too difficult to also provide an onLoadEnd and maybe even also an onLoad which match the functionality of react-native's Image component.

vovkasm commented 7 years ago

Got it, thanks!

I currently focused to implement proper borders (#2) and it is really hard work. After that will implement callbacks.

PRs of course welcomed ;-)