mirror of
https://github.com/kamranahmedse/developer-roadmap.git
synced 2025-01-17 22:28:32 +01:00
Add preloading of ad image
This commit is contained in:
parent
1d1541386f
commit
75a6c9133c
@ -28,6 +28,10 @@ export function StickyTopSponsor(props: StickyTopSponsorProps) {
|
||||
return;
|
||||
}
|
||||
|
||||
// preload the image so that we don't see a flicker
|
||||
const img = new Image();
|
||||
img.src = sponsor.imageUrl;
|
||||
|
||||
// hide the onboarding strip when the sponsor is visible
|
||||
isOnboardingStripHidden.set(true);
|
||||
}, [sponsor]);
|
||||
|
Loading…
x
Reference in New Issue
Block a user