Capítulo 203 de 988

Chapter 203: preloadGif()

Core Idea

_available from v3. 3.

Key Concepts

  • Options
  • requestInit?<AvailableFrom v="4.0.471" />
  • See also

Code Examples

const { waitUntilDone, free } = preloadGif(
  "https://media.giphy.com/media/xT0GqH01ZyKwd3aT3G/giphy.gif"
);

waitUntilDone().then(() => {
  console.log("The GIF is now ready to play!");

  // Later, free the memory of the GIF
  free();
});
  • What it demonstrates: Usage pattern for preloadGif() from the official docs.

Key Takeaways

  1. Understand options when working with preloadGif().
  2. Understand requestinit?<availablefrom v="4.0.471" /> when working with preloadGif().
  3. Understand see also when working with preloadGif().

Connects To

  • Animatedimage: related page in the Assets & Media section.
  • Delaying: related page in the Assets & Media section.
  • Exporting: related page in the Assets & Media section.