Commit Graph

3562 Commits

Author SHA1 Message Date
Martin Konicek e612690413 Add license headers to local-cli
Reviewed By: martinbigio

Differential Revision: D2559969

fb-gh-sync-id: d8cd52435213729ff73a1f039eb0378b28f8d10e
2015-10-20 09:55:21 -07:00
Martin Konicek 82fad33af7 Breaking change: Remove redundant packager entry point
Summary: We have too many ways to start the packager:
- react-native start
- npm start
- ./packager/packager.sh
- ./packager/launchPackager.command

This removes yet another one. According to the [npm docs](https://docs.npmjs.com/files/package.json)
this creates `/usr/local/bin/react-native-start`. Let's kill it.

public

Reviewed By: martinbigio

Differential Revision: D2559953

fb-gh-sync-id: e3b41a0622e6168fe686cdf9c93714dbf02f5965
2015-10-20 09:54:30 -07:00
James Ide 93c56a0e90 Expose the projectRoots option
Summary: This was already implemented -- just documenting it in the CLI.
Closes https://github.com/facebook/react-native/pull/3246

Reviewed By: svcscm

Differential Revision: D2560211

Pulled By: martinbigio

fb-gh-sync-id: c4e4d974db28d6251636ff38bfcb0afdf5148de7
2015-10-20 09:49:27 -07:00
Alex Kotliarskyi 3506f55ece Add "React Native: Under the Hood" to videos 2015-10-20 09:48:00 -07:00
David Aurelio fb46e39cad Make the modification time of the transformer file relevant for the cache.
Reviewed By: amasad

Differential Revision: D2554956

fb-gh-sync-id: cc76f083594aac04c74a4ef271305238b06710eb
2015-10-20 09:46:23 -07:00
Nick Lockwood dbe37e7898 Improved AsyncLocalStorage performance
Reviewed By: javache

Differential Revision: D2540626

fb-gh-sync-id: f94def7463075d40c2dcfea1cb4c01502aefa117
2015-10-20 09:42:23 -07:00
Krzysztof Magiera 4849aabecc Stop propagating requestLayout up the view hierarchy.
Differential Revision: D2560183

fb-gh-sync-id: e62acc3eb70a78ae4526bfe696e51349be957ae3
2015-10-20 08:46:21 -07:00
Andy Street 1b55e4657c Load JS bundle after CatalystInstance has been attached to the ReactContext
Reviewed By: andreicoman11

Differential Revision: D2550062

fb-gh-sync-id: 05790e8c092c7dd28669ffd48f7d7d2dffd6546e
2015-10-20 06:24:25 -07:00
Nick Lockwood 1d6d1189f0 Improved threading for image loader
Summary: public

The image loader was previously returning on the main thread, which could lead to poor performance due to various call sites doing further image processing (resizing, cropping, etc.) directly in the completion block.

This diff modifies the loader to return on a background thread (the same one used to load the image), and updates the call sites to dispatch to the explicit thread they need.

Reviewed By: javache

Differential Revision: D2549774

fb-gh-sync-id: fed73b7c163fdf67ff65bae72ab1986327e75815
2015-10-20 05:02:23 -07:00
Jimmy Mayoukou 77154a7581 Fix typos in example descriptions.
Summary: Closes https://github.com/facebook/react-native/pull/3095

Reviewed By: svcscm

Differential Revision: D2559729

Pulled By: foghina

fb-gh-sync-id: 70dbd39de86e6377d32d1628c77ff10510ac3ae5
2015-10-20 04:38:21 -07:00
Tadeu Zagallo 89c1747c33 Implement asm trampoline rather forwardInvocation
Summary: public

The profiler overrides all the methods of all the BridgeModules, and in order to
`start` and `end` the profiler at the function invocation time it used `NSInvocation`,
which is slow.

Replace it with a simple assembly method based on `objc_msgSend`.

Reviewed By: jspahrsummers

Differential Revision: D2550807

fb-gh-sync-id: 88ca08f9d6bfcd3035bda9304c93566c8818b46f
2015-10-20 04:14:09 -07:00
Martin Konicek 1b29690496 [docs] Tweak Android setup screenshot 2015-10-20 12:44:39 +02:00
Martin Konicek d41cedb8fc Update DevelopmentSetupAndroid.md 2015-10-20 12:35:48 +02:00
Martin Konicek 4d9b05cfb2 [docs] Simplify Android setup instructions 2015-10-20 12:30:54 +02:00
Edoardo Moreni 67498a4b6d CANDDi's iOS app 2015-10-20 10:23:50 +01:00
Martín Bigio 8d592650c9 Update rn-cli.config.js 2015-10-19 19:07:34 -04:00
Martín Bigio 17c59ace46 Add `node-fetch` node module to repo
Reviewed By: vjeux

Differential Revision: D2542225

fb-gh-sync-id: a94e799d5595eb7909b42bc8acb6d80259ca1609
2015-10-19 15:00:26 -07:00
Brent Vatne d03bf216b1 Remove link to IRC in CONTRIBUTING.md, not used anymore 2015-10-19 12:27:17 -07:00
Brent Vatne 61ad255629 Merge pull request #3519 from ptmt/patch-3
Add info about react-native channel on DiscordApp
2015-10-19 12:25:50 -07:00
Brent Vatne ac5e2a41bb Merge pull request #3520 from purposecampaigns/add-foodstand-to-showcase
Add Foodstand to RN showcase
2015-10-19 12:24:31 -07:00
Justin Spahr-Summers 123516d556 Reload RCTImageView when it's displaying the default image
Summary: public

If the frame is set, or the image view moves to a window, we should attempt to load the "real" image. The sizing logic shouldn't kick in if we're only displaying the default image.

Resolves https://github.com/facebook/react-native/issues/3460.

Reviewed By: tadeuzagallo

Differential Revision: D2555316

fb-gh-sync-id: c0c13070ee080bad2b30ca01d9d5173bead406e3
2015-10-19 10:26:24 -07:00
Ricky Reusser d760544652 Add Foodstand to RN showcase 2015-10-19 13:20:05 -04:00
Hedger Wang 73b80773ba supports event capturing and bubbling phases in Navigation context.
Summary: Adds the API that enables the navigation events capturing and bubbling which is the feature
that is enabled if the nested navigation contexts is created by the navigator.

This would allow developer to observe or reconcile navigation events within the navigation tree.

public

./Libraries/FBReactKit/jest

Reviewed By: zjj010104

Differential Revision: D2546451

fb-gh-sync-id: dfc9d16defaa563b9e80fd751a20570f6e524b74
2015-10-19 10:06:22 -07:00
Nick Lockwood 1076f4a172 Added RCTDataRequestHandler
Summary: public

Added RCTDataRequestHandler, which is responsible for loading data URLs. This moves the logic for data URL handling out of RCTImageDownloader (no longer needed) and into the RCTNetwork library, where it makes more sense.

This also means that it is now possible to load data URLs via XHR, and use them for purposes other than just images.

Reviewed By: javache

Differential Revision: D2540964

fb-gh-sync-id: 4f0418bd6b9186f047cc8297276bb970795af104
2015-10-19 09:07:06 -07:00
Dmitry 419549b116 Add info about react-native channel on DiscordApp 2015-10-19 20:47:03 +05:00
Tadeu Zagallo 31f9a690f3 Flush queue every 5ms during JS execution
Summary: public

Implement the iOS side of the optmisation previously implemented in android
(D2485402)

Depends on D2540746

Reviewed By: javache

Differential Revision: D2541118

fb-gh-sync-id: f3590600a6defa2da75c5b7b2cced6ad8bfea6cb
2015-10-19 08:04:24 -07:00
Joe Noon 607527c0d4 (upstream) Prevent SocketRocket killing the connection before notifying of final messages
Summary: wrap NSStreamEventEndEncountered in dispatch_async _workQueue per upstream:
https://github.com/square/SocketRocket/pull/294

CLA completed
Closes https://github.com/facebook/react-native/pull/3493

Reviewed By: svcscm

Differential Revision: D2554892

Pulled By: javache

fb-gh-sync-id: 347a37eb95b20b7e92b985b6908e15462672e83c
2015-10-19 06:47:22 -07:00
Felix Oghină 9dc036d2b9 add gradle tasks for bundling js and assets in template
Summary: This adds gradle tasks that call `react-native bundle` with the correct args to bundle dev/release JS and assets. The dev task is disabled by default, as in dev mode people only use reload JS in most cases.

Submitting this as a pull request to have community visibility, although we have this code internally as well now and this will require an import.

* generate a project with `react-native init`, add some assets, run `./gradlew assembleRelease`, sign & zipalign generated APK, run it -> works
* enable dev bundling task, run `./gradlew installDebug` (not `react-native run-android` so as to not start the packager) -> works

Reviewed By: svcscm

Differential Revision: D2555071

Pulled By: foghina

fb-gh-sync-id: c3d9fcd4c77862e6a4db4e4d8d8cc39ee9dff3ab
2015-10-19 06:33:22 -07:00
Pieter De Baets 59e670e453 Fix a warning about SnapshotView
Reviewed By: majak

Differential Revision: D2553669

fb-gh-sync-id: 2a2b47f9cf7a75403e4e2541b32a4b141b3d08be
2015-10-19 06:10:22 -07:00
Felix Oghină b09e92e1b3 Merge pull request #3499 from willchu/master
Add LoadDocs to showcase
2015-10-19 12:15:15 +01:00
Felix Oghină 81317bd27a Merge pull request #3495 from dsandor/master
Clarified ReactInstanceManager paragraph.
2015-10-19 12:09:35 +01:00
James Ide 45d2c691a3 Start to use the Obj-C JSContext instead of the C API
Summary: The Obj-C API is usually easier to work with, and also makes it very easy to use the C API when necessary (performance, for example). This diff just switches the designated initializer of RCTContextExecutor to take a JSContext instead of JSGlobalContextRef, but the old initializer still works if needed.

I was doing some memory leak investigation and it is easier with ARC so I wanted to incrementally move the executor to Obj-C.
Closes https://github.com/facebook/react-native/pull/2159

Reviewed By: svcscm

Differential Revision: D2554890

Pulled By: tadeuzagallo

fb-gh-sync-id: 75b96d04cddff68fa3daf5d0fafdffad21dae307
2015-10-19 03:51:20 -07:00
Andrei Coman 716f7e8ef2 Don't use MotionEvent timestamp for touch events
Differential Revision: D2554905

fb-gh-sync-id: 7f83e94948cc9ac1024e249764d445fb056f400e
2015-10-19 03:08:23 -07:00
James Ide e3f33ea261 Merge pull request #3500 from jadekler/master
Small readme updates
2015-10-18 21:47:36 -07:00
Jean de Klerk 2be0525b2a Small readme updates
- Link for firefox react dev tools
- Add missing word
2015-10-18 19:00:38 -06:00
Will ec6d41414d add LoadDocs to showcase 2015-10-18 17:34:59 -07:00
David Sandor c0a2c96d9b Clarified ReactInstanceManager paragraph. 2015-10-18 15:55:21 -05:00
Brent Vatne 7827b35443 [Website] Update support section to link to Discord 2015-10-18 12:39:43 -07:00
Brent Vatne 3759511951 Merge pull request #3490 from hswolff/ios-device-docs
Update documentation with improved Cocoapods workflow
2015-10-18 12:02:51 -07:00
Brent Vatne e59b28e6ca [README] Link to Reactiflux Discord invite 2015-10-18 11:58:59 -07:00
Harry Wolff 6949be63e4 Update documentation with improved Cocoapods workflow 2015-10-18 09:48:48 -04:00
Nick Lockwood 16a48ae0c3 Fixed "Unrecognized request token" red box
Summary: public

There was a race condition issue in RCTDownLoadTask whereby the request handler would sometimes call one of the delegate methods before setup was complete, causing an error to be logged because the request token had not been set, and causing te request to fail because the class was not yet set up.

This diff fixes that issue by adding an explicit `start` method to RCTDownloadTask, and changing the setup order to allow for the request to call back immediately without this being treated as an error.

Reviewed By: tadeuzagallo

Differential Revision: D2553628

fb-gh-sync-id: 5ca4e791574a632ccbf2e873e28ac88bffdf851d
2015-10-17 09:34:23 -07:00
Andrei Coman f01272b031 Fix touches with pointer events backtrack
Differential Revision: D2553642

fb-gh-sync-id: b1788879bfbb564a291ada0e7ac206f567780f8a
2015-10-17 06:31:26 -07:00
Hedger Wang a2524bac33 Support nested navigation context.
Reviewed By: fkgozali

Differential Revision: D2525434

fb-gh-sync-id: 18e7d672b2cbadc318a207c8812f38d8669bad30
2015-10-17 04:25:26 -07:00
Martin Konicek dcd82a2450 Update RunningOnDeviceIOS.md 2015-10-17 11:26:58 +02:00
Brent Vatne b39b97546a [Docs] Add ViewPagerAndroid to extractDocs 2015-10-16 19:25:43 -07:00
Martín Bigio 8bff2d30ab Use `private-cli`'s server instead of `packager.js`
Reviewed By: vjeux

Differential Revision: D2542027

fb-gh-sync-id: e59f3be17590c1e256a903e04f2f0359c835c8b5
2015-10-16 15:01:23 -07:00
Martín Bigio 5977f494fc Allow user to configure transformer through cl argument
Reviewed By: frantic

Differential Revision: D2547435

fb-gh-sync-id: 77016ee5beba854a4cb58e9ac04b91a7dd76cf3e
2015-10-16 13:26:22 -07:00
James Ide 01f90054cc Merge pull request #3415 from exentrich/patch-1
Add Raindrop.io to showcase
2015-10-16 13:00:30 -07:00
Patrik Tomas Chamelo 1511d8ca1d Invoking devMenu from RCTBridge in prod will crash
Summary: While we shouldn't invoke `bridge.devMenu` in production, doing it will result into a crash.

1. `devMenu` internally calls `RCTBridgeModuleNameForClass([RCTDevMenu class])`
2. `RCTBridgeModuleNameForClass()` calls `moduleName`
3. In the release code `RCTDevMenu` doesn't export the `moduleName` class method.
Closes https://github.com/facebook/react-native/pull/2910

Reviewed By: svcscm

Differential Revision: D2550797

Pulled By: tadeuzagallo

fb-gh-sync-id: 5dfbf905e5a02d9fd3b52f8b3d6eefc4e3ff30b2
2015-10-16 12:15:25 -07:00