Summary: Tests for things introduced over the last 10 weeks
Reviewed By: cpojer
Differential Revision: D4442404
fbshipit-source-id: cf7a14f237360fde083b7e2ffcd9d70aafd0ced6
Summary:
A temporary React Native compatibility fix was added to React in commit [bba0d99](bba0d992d8) and subsequently removed in commit [e612826](e612826650). I noticed this while testing the React Native fiber renderer and attempting to use `Systrace`.
This commit updates React Native to no longer rely on the deprecated method and module.
PS I'm not sure if I should also update `ReactDebugTool` with this commit or wait for a subsequent sync script to update it. I haven't committed to this repo before. Please advise. 😄
Closes https://github.com/facebook/react-native/pull/11970
Differential Revision: D4446219
Pulled By: bvaughn
fbshipit-source-id: f286b8a4d00cdcbfbb49f52b9f1db5231d453f4c
Summary:
Support `xhr.send(data)` for typed arrays.
**Test plan:** run UIExplorer example on iOS and Android.
Closes https://github.com/facebook/react-native/pull/11904
Differential Revision: D4425551
fbshipit-source-id: 065ab5873407a406ca4a831068ab138606c3361b
Summary:
For returnKeyType 'go', 'search' and 'send' Android will call
onEditorAction twice, once with IME_NULL and another time with the respective IME_ACTION.
This change makes sure to only fire one onSubmitEditing by always returning true in onEditorAction, which causes no subsequent events to be fired by android.
Fixes#10443
**Test plan**
1. Create view with TextInput having 'go', 'search' or 'send as `returnKeyType`
```javascript
<View>
<TextInput
returnKeyType='search'
onSubmitEditing={event => console.log('submit search')}></TextInput>
<TextInput
returnKeyType='go'
onSubmitEditing={event => console.log('submit go')}></TextInput>
<TextInput
returnKeyType='send'
onSubmitEditing={event => console.log('submit send')}></TextInput>
</View>
```
2. Input some text and click submit button in soft keyboard
3. See event fired only once instead of two times
Closes https://github.com/facebook/react-native/pull/11006
Differential Revision: D4439110
Pulled By: hramos
fbshipit-source-id: 5573b7f15f862b432600ddd3d61a0852ce51b2b3
Summary:
add a Tencent education app 腾讯课堂 , which is a hybrid app , It's index page use ReactNative
Closes https://github.com/facebook/react-native/pull/10985
Differential Revision: D4381877
Pulled By: hramos
fbshipit-source-id: 7f524b8993844184ef2816a14cde188608fe5d30
Summary:
Simple fix for a typo in the webview examples.
Closes https://github.com/facebook/react-native/pull/11794
Differential Revision: D4393755
fbshipit-source-id: 43939c4f6eaede51a0e3948181eb58132ba84191
Summary:
This replaces a polymorphic method with three separate methods that support the different used invocations.
In isolation, this leads to a 25% speedup.
Shoutout to trueadm for teaching me about this.
Reviewed By: trueadm
Differential Revision: D4436781
fbshipit-source-id: 3dce83556debf19d5305c4566a56b9e9565e85bc
Summary:
**Motivation:**
According to the meeting notes published by mkonicek yesterday, RN should support `yarn run ios` and `yarn run android` commands.
**Test plan (required)**
- [x] Generate a new project and start scaffolded app using `yarn(npm) run ios(android)`
Closes https://github.com/facebook/react-native/pull/12004
Differential Revision: D4441837
Pulled By: mkonicek
fbshipit-source-id: 250f7a9e1efc59e0caa5c2c071b59b97e14e939b
Summary:
Hi, here are some typo fixes in the documentation related to Android native modules:
* Add missing package and imports for the second part of the basic tutorial (register module)
* Add missing `public` keyword
* Remove incongruous word
Closes https://github.com/facebook/react-native/pull/11938
Differential Revision: D4439220
Pulled By: hramos
fbshipit-source-id: e7086fe384ed6238306abf0ee72c944fac53ad7b
Summary:
Also fix lint errors about Buffer being undefined by adding env: node to the eslint config for local-cli.
Tested on windows 10.
Closes https://github.com/facebook/react-native/pull/11959
Differential Revision: D4438903
Pulled By: hramos
fbshipit-source-id: 28d5edd662dd1e63dedf1274ff0a21af4df84f5e
Summary:
Adding Yeti Smart home to the showcase list
Closes https://github.com/facebook/react-native/pull/11880
Differential Revision: D4438886
Pulled By: hramos
fbshipit-source-id: db43923b46a0f3092d70aaf56f0e7ff94068dd50
Summary:
Without allowing Native Responder on Android, ListView get's Deadlocked while trying to scroll. This happens as soon as a PanResponder fires.
This Commit prevents this Issue and the iOS Optimization for Locking / Unlocking Listview Scrolls does a good job on Android too. So there's no need to prevent the Native Responder.
**Test plan (required)**
Compile on Android in Production Mode and try to scroll before and after this change.
Closes https://github.com/facebook/react-native/pull/8556
Differential Revision: D4438057
Pulled By: hramos
fbshipit-source-id: 05f3b7e6b4e49f5c941c7e1ce72c8bf6d66a9a28
Summary:
Add one more parameter which can specify the keyboard type of first text input(if exists) to AlertIOS.prompt().
Example usage:
`AlertIOS.prompt('Type a phone number', null, null, 'plain-text', undefined, 'phone-pad')`
Closes https://github.com/facebook/react-native/pull/8781
Differential Revision: D4437900
Pulled By: hramos
fbshipit-source-id: 8141cc0d7c70d13603cd5a1d5ea3f1ab1ce437a6
Summary: Introduced IS_TESTING flag on Platform module for android as well. This is useful for testing environment.
Reviewed By: mmmulani
Differential Revision: D4429662
fbshipit-source-id: 33711d7fb5666f0bac8aee444b71261f7f12770f
Summary:
Many websites use domstorage and never think of its unavailability, which usually leads to a blank page on android and hard for developers to debug. I think it's better to enable domstorage by default, for convenience and consistency to iOS and PC.
Closes https://github.com/facebook/react-native/pull/11333
Differential Revision: D4437165
Pulled By: hramos
fbshipit-source-id: a00441cb5214cca27927471d3a33f030b9ff9b52
Summary: Switch to using IS_TESTING on the Platform module. While IS_TESTING has to be explicitly set in the test harness, this makes it more usable and stops people from relying on brittle variables in the (larger) environment.
Reviewed By: fkgozali
Differential Revision: D4423661
fbshipit-source-id: 27a80867778b9374bcba67b69f9c93d32c0a74b0
Summary: Since we don't support this, we should throw early. Also tries to improve the error message when adding a node that doesn't have a YogaNode to a node that can't measure itself.
Reviewed By: andreicoman11
Differential Revision: D4421542
fbshipit-source-id: e0be8cdd763091145e5e6af2db91515f4d236b37
Summary:
Adding a link to the Convoy Driver Android app to the showcase
Closes https://github.com/facebook/react-native/pull/11830
Differential Revision: D4427024
Pulled By: hramos
fbshipit-source-id: 641ed9c4dce3b69d141a9328f41ce04ea1cd049c
Summary:
In the context of an app an image exists in three resolutions on the server: `thumb` (30px) `feed` (300px) `full` (900px). When looking at an individual item a user can come either from the feed, via a permalink or from other parts of the app. This allows a situation where the `feed` image might or might not already be loaded somewhere in the app. In the detail view I want to render `thumb` with a blur (to quickly display something), then the `feed` image if it exists to have something decent to display until `full` loads. However it is quite a waste to load the `feed` image if it isn't already in cache, and will slow down the time until `full` is loaded. It is possible to track the navigation from feed->detail and that the `feed` image has actually completed loading by the feed component however as component hierarchies grow this turns into quite a lot of prop passing and bad separation of concerns.
NSURLRequests accepts a [Cache Policy](https://developer.apple.com/reference/fo
Closes https://github.com/facebook/react-native/pull/10844
Differential Revision: D4425959
Pulled By: lacker
fbshipit-source-id: 679835439c761a2fc894f56eb6d744c036cf0b49
Summary:
**Motivation**
This finishes the job of #11817, removing the previously deprecated method. See https://github.com/facebook/react-native/issues/11736 for more context.
**Test plan**
There were no tests for this method, and I searched the whole project to make sure we weren't relying on it anywhere.
Closes https://github.com/facebook/react-native/pull/11854
Differential Revision: D4421671
Pulled By: javache
fbshipit-source-id: 67e0db8d3c594ad3ccd6ccdae08f8ce49ddb8a34
Summary:
**Motivation**
See if we can safely run a WebSocket test in Travis CI
Closes https://github.com/facebook/react-native/pull/11433
Differential Revision: D4342024
Pulled By: ericvicenti
fbshipit-source-id: 137fb0c39ed7ea3726e2778d5c0bdac4cef6ab89
Summary:
Fixes https://github.com/facebook/react-native/issues/11861 - the release config is currently broken for projects created by `react-native init` in `master`, 0.40 and 0.39.
I'm still investigating when and how this got broken but this seems to be a clean fix. I've added `-ObjC` as well to match the main target but I'm not sure yet whether that's necessary.
To test:
```
react-native init fooproject --version react-native@rh389/react-native#missinglinkerflags
```
Open in XCode, Edit scheme (⌘<), Change `Build Configuration` to `Release`, build.
Update: The `-lc++` flag became necessary when 33deaad196 landed because of the libstdc++ dependencies of `RCTLog`. Still not sure about `-ObjC`. javache ?
Closes https://github.com/facebook/react-native/pull/11889
Differential Revision: D4421685
Pulled By: javache
fbshipit-source-id: 954edaef773f8cef7b7ad671fa4d1f2bfc2f20f2
Summary:
Fix#326. I'll open another PR once this one gets accepted to add support for `YGLayoutGetBorder` 👌
Closes https://github.com/facebook/yoga/pull/335
Reviewed By: gkassabli
Differential Revision: D4409399
Pulled By: emilsjolander
fbshipit-source-id: 8153f6701cab60b55a485f6d2e0b9f7767481090