Skip to content

Commit 70558b9

Browse files
nickjuntillafacebook-github-bot
authored andcommitted
Add the import statement to examples
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
1 parent 5317b68 commit 70558b9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Libraries/Components/Button.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ const invariant = require('fbjs/lib/invariant');
3838
* Example usage:
3939
*
4040
* ```
41+
* import { Button } from 'react-native';
42+
* ...
43+
*
4144
* <Button
4245
* onPress={onPressLearnMore}
4346
* title="Learn More"

0 commit comments

Comments
 (0)