Add Import method to usage instructions.

Use `var LinearGradient = require('react-native-linear-gradient');` as shown in the Login example app does not work.
This commit is contained in:
Joshua Pinter 2016-09-10 21:17:27 -06:00 committed by GitHub
parent 2a9f95efa4
commit 73df1d3602
1 changed files with 2 additions and 0 deletions

View File

@ -97,6 +97,8 @@ The following code will produce something like this:
![Example code result](https://raw.githubusercontent.com/brentvatne/react-native-linear-gradient/master/images/example.png)
```javascript
import LinearGradient from 'react-native-linear-gradient';
// Within your render function
<LinearGradient colors={['#4c669f', '#3b5998', '#192f6a']} style={styles.linearGradient}>
<Text style={styles.buttonText}>