Dave Sibiski
e163df3567
Adds process.env.NODE_ENV polyfill
...
Summary:
There are many libraries that use `NODE_ENV` to check whether the code is running in
"production" mode or not. This allows those library authors to not have to add conditionals
for React Native.
One such library is Redux: https://github.com/gaearon/react-redux/pull/40
Thanks to @brentvatne for providing the solution via this tweet (via his phone in the airport 😉 ): https://twitter.com/notbrent/status/630440250951749632
/cc @vjeux @gaearon @zpao @amasad
Closes https://github.com/facebook/react-native/pull/2279
Github Author: Dave Sibiski <dsibiski@gmail.com >
2015-08-10 19:51:05 -08:00
Martín Bigio
a303a42e28
[react-packager] Add more granular Activity logging
2015-08-10 16:25:04 -08:00
Martín Bigio
2afeb8fbe6
[react-packager] Promote Cache to top level
...
Summary:
The cache is only used for JSTransformer at the moment. We're doing IO and some computation to get each module's name, whether is a haste or node module and it's dependencies. This work happens on startup so by caching this value we shouldbe able to reduce the start up time. Lets promote the Cache to the Packager level to be able to use it by any of the components of the packager. For now, on this diff we'll start using it to cache the mentioned fields.
Also we had to introduce the concept of fields in the cache as manually merging the date we had for each path is not possible as we're using promisses all around. With the new API, each field is a promise.
@amasad and I did some manual testing to measure the impact of this change and looks like it's saves 1 second when building the haste map (which represents 50% of the time). Overall this reduces 1 second of start up time which was currently about 8s on my mac book pro.
2015-08-10 16:25:03 -08:00
Christopher Chedeau
56059e92df
Merge pull request #2288 from ide/iojs-docs
...
[docs] remove instructions to install node/io.js with brew
2015-08-10 15:46:36 -07:00
Nick Lockwood
5d20b9065d
Fix RKHTTPRequestHandler crash
2015-08-10 13:46:47 -08:00
James Ide
fd4e75644f
[docs] remove instructions to install node/io.js with brew
...
nvm is way better than homebrew for managing node installations:
- can install multiple versions
- can choose which version of node to install
- easy to clean up under ~/.nvm
- there are still some rough edges with /usr/local on El Cap -- nvm avoids those altogether
2015-08-10 14:31:48 -07:00
Nick Lockwood
6e2e02ab08
Merge pull request #2281 from jacob-israel-turner/patch-2
...
Grammar
2015-08-10 22:00:03 +01:00
Nick Tuckett
f309540f69
[react_native] JS files from D2327386: Simplified unimplemented SliderIOS on Android
2015-08-10 08:33:39 -08:00
Nick Lockwood
b489c9aa43
Fixed perf issue due to use of regex in +[RCTConvert NSURL:]
2015-08-10 07:13:36 -08:00
Jacob Turner
5b5cadeb30
Grammar
2015-08-10 14:34:27 +01:00
Dorota Kapturkiewicz
59b974eafb
[ReactNative] make AdsManager floater and TouchableHighlight accessible
2015-08-10 04:41:09 -08:00
Christopher Chedeau
50d5f86bf8
Merge pull request #2273 from vjeux/fix_az
...
[Website] Fix a-z order in props
2015-08-08 10:28:39 -07:00
Christopher Chedeau
c1a0a72275
[Website] Fix a-z order in props
2015-08-08 10:28:05 -07:00
Nick Lockwood
94caefa9c2
Converted RCTDevLoadingView to a module and fixed url display when using delegate
2015-08-08 03:31:49 -08:00
Nick Lockwood
b82ac9bf07
Reverted to pre-init of queues to fix UIExplorer tests.
2015-08-08 01:47:43 -08:00
Alex Kotliarskyi
e21fb91786
[ReactNative] Show banner promoting DevTools
...
Summary:
When React DevTools is not installed, React prints a tiny warning to the console.
However, in debugger.html we have a lot of free space we could use to promote
React DevTools more actively.
2015-08-07 15:23:22 -08:00
Philipp von Weitershausen
0f5190e9f3
[React Native] Provide a way to get a list of registered apps in AppRegistry
2015-08-07 11:05:25 -08:00
Tadeu Zagallo
331e4a96e9
[ReactNative] Preload ModuleData queue
...
Summary:
The module's methodQueue wasn't being created when accessing the modules directly
on the bridge, without going through JS. Preload the queue for now to fix internal
breakages, but I'll figure out a better way to keep it lazy afterwards.
2015-08-07 11:05:09 -08:00
Ben Alpert
2d66e10ec4
[ReactNative] Delay sending touches to JS until dependent (native) gesture recognizers fail
...
Summary:
Previously, JS touches were being interpreted simultaneously with native gesture recognizers.
2015-08-07 10:56:26 -08:00
Alexander Kotliarskyi
3aec8ee72d
Merge pull request #2267 from frantic/hide-npm-output
...
Hide npm output when doing react-native init
2015-08-07 11:37:49 -07:00
Felix Oghină
205a2c0bfc
[react_native] JS files from D2318945: Implement a slider for React Native Android
2015-08-07 10:15:52 -08:00
Alex Kotliarskyi
2ddf3d942d
Hide npm output when doing react-native init
2015-08-07 10:59:59 -07:00
Christopher Chedeau
a91f44d7fd
Merge pull request #2264 from vjeux/platform_props
...
[Website] Platform-specific props
2015-08-07 10:39:04 -07:00
Christopher Chedeau
6e9ceaa348
[Website] Platform-specific props
...
We are annotating platform-specific props with a special @platform tag in the docblocks. This pull request adds a little [ios] tag before the name and sorts the props such as generic ones are before platform-specific ones.
2015-08-07 10:31:07 -07:00
Tadeu Zagallo
6cd0709bc0
[ReactNative] Parellelise bridge startup
...
Summary:
Parallelise the bridge startup so we don't keep waiting for the source to load.
2015-08-07 06:48:30 -08:00
Nick Lockwood
3cef3010e6
Fix RCTAssert logic
2015-08-07 06:11:49 -08:00
Andy Street
1d452f3e4d
[ReactNative] Remove testID from root view
2015-08-07 05:23:40 -08:00
Tj
c933087567
CMD+R should post a refresh notification.
...
Summary:
For the sake of consistency, `cmd+r` should just post a refresh notification. This way other tools can also observe and react to the refresh without ugly hacks.
Closes https://github.com/facebook/react-native/pull/2175
Github Author: Tj <tfallon@mail.depaul.edu >
2015-08-07 04:39:21 -08:00
Vladislav Alexeev
9edad17a15
Use Dynamic Text Size Multipliers from Wilde in ReactNative Module
2015-08-07 03:18:20 -08:00
Nick Lockwood
ffa7dbcbf1
Fixed onLayout redbox issue
2015-08-07 02:58:48 -08:00
Jason Zhekov
a8211e32d2
Fix typo
...
Summary:
Closes https://github.com/facebook/react-native/pull/2055
Github Author: Jason Zhekov <jasssonpet@gmail.com >
2015-08-06 20:22:24 -08:00
Nick Lockwood
deba13f698
Refactor RCTUIManager
...
Summary:
Moved the view creation & property binding logic out of RCTUIManager into a separate RCTComponentData class - this follows the pattern used with the bridge.
I've also updated the property binding to use pre-allocated blocks for setting the values, which is more efficient than the previous system that re-contructed the selectors each time it was called. This should improve view update performance significantly.
2015-08-06 15:49:35 -08:00
James Ide
3309f6da80
Merge pull request #2252 from ide/iojs-docs
...
[Docs] Update setup instructions to install io.js 2.x instead of latest
2015-08-06 14:24:15 -07:00
James Ide
554f23276b
[Docs] Update setup instructions to install io.js 2.x instead of latest
...
The ws module has not been updated to work with 3.x quite yet.
2015-08-06 14:22:45 -07:00
Martín Bigio
aefdf82cdc
[JSAppServer] Don't keep track of not found packages
2015-08-06 11:34:56 -08:00
Andrei Coman
327f84b967
[ReactNative] Sync [react_native] Implement TextInput editable
2015-08-06 11:07:06 -08:00
Tadeu Zagallo
48548fedbf
[ReactNative] Fix RCTTextField crash on iOS7
...
Summary:
RCTTextField was its own delegate, that was causing a stall on the main thread,
see more here:
http://stackoverflow.com/questions/19758025/uitextfield-delegate-jumping-to-100-cpu-usage-and-crashing-upon-using-keyboard
2015-08-06 09:56:17 -08:00
Andrei Coman
0d981c06de
[ReactNative] Sync [react_native] Text Input missing letters fix
2015-08-06 04:59:09 -08:00
Hedger Wang
8463625bd9
[Navigation]: Add a method to map the stack routes to an array.
...
Summary:
Add a method to map the stack routes to an array.
2015-08-06 02:01:59 -08:00
Thomas Aylott
a6ff11f1d2
[react-packager] Fixes stack traces
...
Summary:
TransformErrors weren't showing stack traces, making it hard to debug problems in transformer code.
2015-08-05 12:46:30 -08:00
James Ide
d4eac3ddca
[RFC][Rendering] Add shouldRasterizeIOS to View components
...
Summary:
Exposes the `shouldRasterize` property. Fixes #1986 .
Closes https://github.com/facebook/react-native/pull/2226
Github Author: James Ide <ide@jameside.com >
2015-08-04 15:37:38 -08:00
Tj
d8f43105ed
[ListView] Fix RCTScrollView stickyHeader touch passing.
...
Summary:
Point must be converted to the stickyHeader's coordinate space and then passed to the stickyHeaders hitTest:withEvent: method in order to be correctly routed to any subviews of the stickyHeader.
This resolves this [issue](https://github.com/facebook/react-native/issues/2075 ).
Closes https://github.com/facebook/react-native/pull/2224
Github Author: Tj <tfallon@Tjs-MBP.local >
2015-08-04 17:10:19 -08:00
Nick Lockwood
f165bbaf4e
Use +[RCTConvert NSURL:] everywhere instead of +[NSURL URLWithString:]
...
Summary:
RCTConvert's URL: method gracefully handles unescaped urls, local file urls, urls containing unicode, etc. URLWithString doesn't.
2015-08-04 16:26:16 -08:00
Hedger Wang
222594cb44
[Navigator] A method subtract to compute the diff between stack mutation.
...
Summary:
When mutation of a stack happens, we'd like to compute the diff of the stacks (before and after) so that
we can know which routes are removed in the new stack.
This diff adds a new method `substract` which does what we need.
2015-08-04 16:16:17 -08:00
Nick Lockwood
274769fd8c
Added Unicode URL test
2015-08-04 15:37:05 -08:00
Nick Lockwood
9f81d6726c
Merge pull request #2227 from harrykiselev/patch-1
...
Fix link to Apple Developer account registration.
2015-08-04 22:16:26 +01:00
Harry V. Kiselev
01deb0b03d
Fix link to Apple Developer account registration.
2015-08-05 00:07:42 +03:00
Brent Vatne
257bbb5255
[Docs] Add newsletter to top-level header
2015-08-04 13:47:52 -07:00
Alex Akers
bb883bfb61
Update offscreen image fix with window checking
...
Summary:
2015-08-04 08:05:12 -08:00
James Ide
eab7b00cee
[JSContext] Define ContextExecutor.setContextName for debugging
...
Summary:
Add a method that lets JS set the name of the JSContext for debugging purposes. I check `JSGlobalContextSetName` since it is not available on iOS 7.
Closes https://github.com/facebook/react-native/pull/2144
Github Author: James Ide <ide@jameside.com >
2015-08-04 06:08:14 -08:00