diff --git a/releases/next/docs/image.html b/releases/next/docs/image.html index 489461a9d0b..5044fc3e9e0 100644 --- a/releases/next/docs/image.html +++ b/releases/next/docs/image.html @@ -63,7 +63,7 @@ class DisplayAnImageWithStyle extends compile 'com.facebook.fresco:webpsupport:0.11.0' }

Also, if you use GIF with ProGuard, you will need to add this rule in proguard-rules.pro :

-keep class com.facebook.imagepipeline.animated.factory.AnimatedFactoryImpl { public AnimatedFactoryImpl(com.facebook.imagepipeline.bitmaps.PlatformBitmapFactory, com.facebook.imagepipeline.core.ExecutorSupplier); -}

Props #

onLayout function #

Invoked on mount and layout changes with +}

Props #

onError function #

Invoked on load error with {nativeEvent: {error}}.

onLayout function #

Invoked on mount and layout changes with {nativeEvent: {layout: {x, y, width, height}}}.

onLoad function #

Invoked when load completes successfully.

onLoadEnd function #

Invoked when load either succeeds or fails.

onLoadStart function #

Invoked on load start.

e.g., onLoadStart={(e) => this.setState({loading: true})}

resizeMode enum('cover', 'contain', 'stretch', 'repeat', 'center') #

Determines how to resize the image when the frame doesn't match the raw image dimensions.

  • cover: Scale the image uniformly (maintain the image's aspect ratio) so that both dimensions (width and height) of the image will be equal @@ -100,7 +100,7 @@ rounded buttons, shadows, and other resizable assets. More info in the should be either a local file path or the name of a static image resource (which should be wrapped in the require('./path/to/image.png') function).

  • width, height - can be specified if known at build time, in which case these will be used to set the default <Image/> component dimensions.
  • scale - used to indicate the scale factor of the image. Defaults to 1.0 if -unspecified, meaning that one image pixel equates to one display point / DIP.
  • number - Opaque type returned by something like require('./image.jpg').

iosonError function #

Invoked on load error with {nativeEvent: {error}}.

iosonPartialLoad function #

Invoked when a partial load of the image is complete. The definition of +unspecified, meaning that one image pixel equates to one display point / DIP.

  • number - Opaque type returned by something like require('./image.jpg').
  • iosonPartialLoad function #

    Invoked when a partial load of the image is complete. The definition of what constitutes a "partial load" is loader specific though this is meant for progressive JPEG loads.

    iosonProgress function #

    Invoked on download progress with {nativeEvent: {loaded, total}}.

    Methods #

    static getSize(uri, success, failure): #

    Retrieve the width and height (in pixels) of an image prior to displaying it. This method can fail if the image cannot be found, or fails to download.

    In order to retrieve the image dimensions, the image may first need to be