Updating the documentation for getSize()
Summary: Clearly state that the `getSize()` does not work for static image resources because it is assumed the developer knows their static image resource size (the reason I got from a comment on a github issue by a react native contributor). This missing documentation cost me about 30 minutes to figure out why it didn't work for my static image resource and so I decided to update the documentation 💃 Closes https://github.com/facebook/react-native/pull/11645 Differential Revision: D4533463 Pulled By: lacker fbshipit-source-id: 70e175ea30a5540c8a9f2a0c040585c711d82ac3
This commit is contained in:
parent
abc483a653
commit
0150bc76eb
|
@ -289,6 +289,8 @@ const Image = React.createClass({
|
|||
* does not fully load/download the image data. A proper, supported way to
|
||||
* preload images will be provided as a separate API.
|
||||
*
|
||||
* Does not work for static image resources.
|
||||
*
|
||||
* @param uri The location of the image.
|
||||
* @param success The function that will be called if the image was successfully found and width
|
||||
* and height retrieved.
|
||||
|
|
Loading…
Reference in New Issue