Skip to content

Commit

Permalink
Add the import statement to examples
Browse files Browse the repository at this point in the history
Summary:
As a new user it took me a while to figure out you can import these examples directly. The import statement completes the example for new users like me who have no idea these components can be imported. It is a very important piece of information and it is hard to find otherwise.

I think this should be added to all the other component examples as well.

Documentation only.
Closes #15501

Differential Revision: D5882436

Pulled By: hramos

fbshipit-source-id: 2da0fe4c7c41e2fdb6b13a945460e17e16442d62
  • Loading branch information
nickjuntilla authored and facebook-github-bot committed Sep 21, 2017
1 parent 5317b68 commit 70558b9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Libraries/Components/Button.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ const invariant = require('fbjs/lib/invariant');
* Example usage:
*
* ```
* import { Button } from 'react-native';
* ...
*
* <Button
* onPress={onPressLearnMore}
* title="Learn More"
Expand Down

0 comments on commit 70558b9

Please sign in to comment.