-
Notifications
You must be signed in to change notification settings - Fork 24.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Summary: Simplified Networking Guide, based on the old Network polyfill doc. This guide strongly recommends using fetch, while still informing the user about React Native's support for other libraries. In order to provide an actual working networking example, a `movies.json` file is added at the root of the site, allowing the user to fetch a small blob of JSON: ``` fetch('http://facebook.github.io/react-native/movies.json') ``` ![networking](https://cloud.githubusercontent.com/assets/165856/16321804/d2bd7c6a-3953-11e6-9fc5-30baaa38d7a4.png) Closes #8381 Differential Revision: D3479018 Pulled By: lacker fbshipit-source-id: 1f2078bf2414a13f7f77d5af55b08948909093a3
- Loading branch information
Showing
2 changed files
with
67 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"title": "The Basics - Networking", | ||
"description": "Your app fetched this from a remote endpoint!", | ||
"movies": [ | ||
{ "title": "Star Wars", "releaseYear": "1977"}, | ||
This comment has been minimized.
Sorry, something went wrong. |
||
{ "title": "Back to the Future", "releaseYear": "1985"}, | ||
{ "title": "The Matrix", "releaseYear": "1999"}, | ||
{ "title": "Inception", "releaseYear": "2010"}, | ||
{ "title": "Interstellar", "releaseYear": "2014"} | ||
] | ||
} |
nit: shouldn't the years be numbers instead of strings?