Image
Analog of the Image component at React Native,
React Sketchapp.
Renders Figma rectangle node with background.
Props
| Prop | Type | Default | Note | 
|---|---|---|---|
name | String | The name to be displayed in the Figma Layers List | |
source | String | Path for loading image | |
resizeMode | ResizeMode | ||
style | Style | ||
onSelectionEnter | Function | Selection enter event callback | |
onSelectionLeave | Function | Selection leave event callback | |
onLayout | Function | Event is fired once the layout has been calculated | |
onNodeId | Fuction | Getting Figma Node ID callback | 
type ResizeMode = 'contain' | 'cover' | 'stretch' | 'center' | 'repeat' | 'none';
Examples
Absolute path supported:
<Image
  source="http://placekitten.com/400"
  resizeMode="contain"
  style={{
    height: 400,
    width: 400,
  }}
/>
Webpack image loader supported:
import * as img from "./icon.png";
...
<Image
  source={img}
  resizeMode="contain"
  style={{
    height: 400,
    width: 400,
  }}
/>