Files
react-native/docs/Basics-Component-Image.md
T
Kevin Lacker 072ef0a0d4 More Resources doc, updating Support doc and quickstart too
Summary:
TLDR even more docs changes

So I created a More Resources doc that aggregates the high-quality-but-off-site stuff. Let's try to put more outlinks there. Also I removed the stuff on Support that was not support, and some misc changes to clean stuff up.
Closes https://github.com/facebook/react-native/pull/8329

Differential Revision: D3471669

Pulled By: JoelMarcey

fbshipit-source-id: 54edd543ced1b3a8f3d0baca5475ac96bae6e487
2016-06-22 14:28:44 -07:00

31 lines
861 B
Markdown

---
id: basics-component-image
title: Image
layout: docs
category: The Basics
permalink: docs/basics-component-image.html
next: basics-component-view
---
Another basic React Native component is the [`Image`](/react-native/docs/image.html#content) component. Like `Text`, the `Image` component simply renders an image.
> An `Image` is analogous to the `<img>` HTML tag when building websites.
The simplest way to render an image is to provide a source file to that image via the `source` attribute.
This example displays a checkbox `Image` on the device.
```JavaScript
import React from 'react';
import { AppRegistry, Image } from 'react-native';
const AwesomeProject = () => {
return (
<Image source={require('./img/check.png')} />
);
}
// App registration and rendering
AppRegistry.registerComponent('AwesomeProject', () => AwesomeProject);
```