Summary: Currently on error I have following output:
```
ERROR Packager can't listen on port 8081
Most likely another process is already using this port
Run the following command to find out which process:
lsof -n -i4TCP:8081
You can either shut down the other process:
kill -9 <PID>
or run packager on different port.
See http://facebook.github.io/react-native/docs/troubleshooting.html
for common problems and solutions.
/Users/nucleartux/Work/projects/react-native/local-cli/server/server.js:90
if (error.code === 'EADDRINUSE') {
^
TypeError: Cannot read property 'code' of undefined
at process.<anonymous> (/Users/nucleartux/Work/projects/react-native/local-cli/server/server.js:104:14)
at emitOne (events.js:77:13)
at process.emit (events.js:169:7)
at process._fatalException (node.js:211:26)
```
Closes https://github.com/facebook/react-native/pull/3765
Reviewed By: svcscm
Differential Revision: D2595537
Pulled By: martinbigio
fb-gh-sync-id: e11ec2e6e8794bf5fe7570e27cd327777d8b300c
Summary: public
We have code in place to ensure that a red box is displayed when bad arguments are sent to exported methods, however the methods were still being called with nil values for those arguments, resulting in crashes if the method wasn't set up to handle nil gracefully.
This diff ensures that methods will not be called if any of the argument conversion functions log an error. It also explicitly checks for nil output for arguments that are marked as nonnull.
Reviewed By: javache, tadeuzagallo
Differential Revision: D2580658
fb-gh-sync-id: aad6be758ea19f9b4521f3f9f0407bf672c0a2dd
Summary: These need to be included while building with CocoaPods.
Closes https://github.com/facebook/react-native/pull/3753
Reviewed By: svcscm
Differential Revision: D2595296
Pulled By: tadeuzagallo
fb-gh-sync-id: f2e2ba729c92c52808ed1b7d23c31f6fa7b9d891
Summary: This addresses #3577 and #3533. It adds the ability to test for subview.clipsToBounds.
Closes https://github.com/facebook/react-native/pull/3750
Reviewed By: svcscm
Differential Revision: D2592878
Pulled By: nicklockwood
fb-gh-sync-id: a87842b87dc0b455120e6007059b5d9a51a53ea2
Summary: public
To improve cold start performance we want to be able to avoid decoding the bundle at all. To make that happen we need to be able to generate a bundle encoded on `ucs2`. This diff adds support for indicating the encoding the Packager should use for bundling.
Reviewed By: davidaurelio
Differential Revision: D2582365
fb-gh-sync-id: 905384272a668910c57a1a2ca6d1b723c39233f8
Summary: This patch adds two pieces of functionality:
- Exposes `JSBundleLoader` to allow a developer to load JavaScript bundles as they choose.
- Adds `ReactBridge.loadScripFromFile` method which loads a JavaScript bundle from an arbitrary file path.
Example usage:
```
JSBundleLoader jsBundleLoader = new JSBundleLoader() {
Override
public void loadScript(ReactBridge reactBridge) {
reactBridge.loadScriptFromFile("/sdcard/Download/index.android.bundle");
}
};
mReactInstanceManager = ReactInstanceManager.builder()
.setApplication(getApplication())
.setJSBundleLoader(jsBundleLoader)
.setJSMainModuleName("") /* necessary due to TODO(6803830) */
.addPackage(new MainReactPackage())
.setInitialLifecycleState(LifecycleState.RESUMED)
.build();
```
cc ide
Closes https://github.com/facebook/react-native/pull/3189
Reviewed By: svcscm
Differential Revision: D2535819
Pulled By: mkonicek
fb-gh-sync-id: f319299dbe29bab3b7e91f94249c14b270d9fec3
Summary: added a new property named 'disable' to SliderIOS
this property prevents the user from being able to slide the slider
Closes https://github.com/facebook/react-native/pull/3730
Reviewed By: svcscm
Differential Revision: D2590154
Pulled By: javache
fb-gh-sync-id: b8a9c82c1b05eb813d9b81180cb1083b3f1852ac
Summary: public
`%xmm` registers weren't being preserved what would cause eventual weird issues
for methods using floats / doubles / etc.
Reviewed By: jspahrsummers
Differential Revision: D2581358
fb-gh-sync-id: 701498def0f05716c665f4749e5154b828bf41ec
Summary: public
Navigator subscribes to its internal animation spring that may still
asks navigator to re-render after being unmounted.
This diff clears the listeners of its animation spring once navigator
is unmounted.
Reviewed By: zjj010104
Differential Revision: D2588434
fb-gh-sync-id: 2b3ee65d3a6c3d45e5c6904d1dc65ac5a3e4534a
Summary: public
Aparently this used to work on 0.11, lets fix it :)
Reviewed By: foghina
Differential Revision: D2557719
fb-gh-sync-id: dcbca077431c1356c89dfc55b71eecff64c7ad3d
Summary: public
I was using `dlsym` as a more elegant way of checking if the function was defined
to prevent crashes if running on an unsupported architecture, but Xcode might
strip the symbol, even with `.no_dead_strip`, if there's no references to the
compilation unit at all.
Replace it with an ugly `#if` that checks if it's any of the supported targets
and extern the function prototype.
Reviewed By: jspahrsummers
Differential Revision: D2581143
fb-gh-sync-id: b004ed351de97f96c04b4a6c914ce55cfcbbbcbb