You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you set a delay and the component is already mounted, when you set ready to false, it will use the same delay to start showing the placeholder. I want to start showing the placeholder immediately after setting ready to false.
It seems to be a misunderstanding, I thought the delay was to keep the placeholder for a while, to avoid the blinking content with fast connections. By the way, the delay is to wait some time to show the placeholder, anyway I can't see a use case for that.
It's exactly the opposite solution to the same problem :)
The delay delays the appearance of the placeholder in case of a fast connection. This way if your content loads fast you can skip the placeholder altogether and avoid the blinking.
If you set a delay and the component is already mounted, when you set
ready
tofalse
, it will use the same delay to start showing the placeholder. I want to start showing the placeholder immediately after settingready
to false.I believe don't need to check the delay to set the
state
ready
tofalse
here:https://github.com/buildo/react-placeholder/blob/master/src/ReactPlaceholder.js#L63
Am I wrong?
The text was updated successfully, but these errors were encountered: