Skip to content
This repository was archived by the owner on Dec 29, 2022. It is now read-only.

Patch 2 Updated with Custom Image Component #7

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open

Patch 2 Updated with Custom Image Component #7

wants to merge 8 commits into from

Conversation

krunalbad
Copy link
Contributor

No description provided.

I have tried with possible solution using fast image so far it works properly. if its okay then you can try merge it!
dependencies updated
`isFast` prop added in `BetterImageProps`
@DaniAkash
Copy link
Member

@krunalbad React Native Fast Image has too many issues which is why I didn't add it to the package. May be we can think of a different approach to allow people use their own image components?

@krunalbad
Copy link
Contributor Author

Yeah we can try that approach! Great suggestion!

@krunalbad krunalbad changed the title Patch 2 Updated with Fast Image Patch 2 Updated with Custom Image Component Dec 27, 2020
@krunalbad
Copy link
Contributor Author

Added possible feature! Please review!

@DaniAkash
Copy link
Member

Thanks @krunalbad
Now that we are allowing custom components, we need to also ensure prop types are properly displayed based on the component

@krunalbad
Copy link
Contributor Author

What are you suggesting? @DaniAkash

@krunalbad
Copy link
Contributor Author

I have tested it on multiple devices of both platforms so far it worked great. One another feature we can add is onLayout as it common for most of the 3rd pkgs out there and even for Image. Let me know your concern. It will help much better in application development!

@DaniAkash
Copy link
Member

I have tested it on multiple devices of both platforms so far it worked great. One another feature we can add is onLayout as it common for most of the 3rd pkgs out there and even for Image. Let me know your concern. It will help much better in application development!

BetterImage extends all the props of regualar image component including onLayout. This should work out of the box

@DaniAkash
Copy link
Member

What are you suggesting? @DaniAkash

Try if you can infer prop types based on the component using typescript

@krunalbad
Copy link
Contributor Author

krunalbad commented Jan 17, 2021

I have tested it on multiple devices of both platforms so far it worked great. One another feature we can add is onLayout as it common for most of the 3rd pkgs out there and even for Image. Let me know your concern. It will help much better in application development!

BetterImage extends all the props of regualar image component including onLayout. This should work out of the box

Yeah I noticed! Great!
Most of the pkgs have this onLayout common.
As there are already otherProps sent to it, so it should work for all quite good.

@krunalbad
Copy link
Contributor Author

What are you suggesting? @DaniAkash

Try if you can infer prop types based on the component using typescript

Sure I'll look into it!

@krunalbad
Copy link
Contributor Author

@DaniAkash Am I missing something here?

@krunalbad
Copy link
Contributor Author

Are you suggesting this change? @DaniAkash
From imageComponent?: Component; to imageComponent?: ReactElement;
or is it something else ? let me know what am i missing here!

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

Successfully merging this pull request may close these issues.

2 participants