Skip to content

Add usePlaceholderAsFailure to show placeholder in case of image loading failure#764

Merged
kean merged 2 commits into
kean:mainfrom
mlight3:mlight3/placeholder
Mar 23, 2024
Merged

Add usePlaceholderAsFailure to show placeholder in case of image loading failure#764
kean merged 2 commits into
kean:mainfrom
mlight3:mlight3/placeholder

Conversation

@mlight3

@mlight3 mlight3 commented Mar 7, 2024

Copy link
Copy Markdown

I added usePlaceholderAsFailure because I think there are a lot of cases where people might want to keep the placeholder visible even if the image fails to load.

@mlight3

mlight3 commented Mar 9, 2024

Copy link
Copy Markdown
Author

@kean The default value of usePlaceholderAsFailure is true, do you think it should be a false?

@kean

kean commented Mar 23, 2024

Copy link
Copy Markdown
Owner

Hey, @mlight3 . Thanks for the PR. Yeah, I think it's worth adding.
I usually avoid extending the API surface unless necessary, but it wouldn't hurt.

@kean kean merged commit eb7c5b8 into kean:main Mar 23, 2024
@kean

kean commented Mar 23, 2024

Copy link
Copy Markdown
Owner

I changed the default behavior to false and renamed it a bit. Thank you for the contribution!

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.

3 participants