react-native/React/Base
Alex Kotliarskyi e2b25c8c9d Add multipart response stream reader
Summary:
Packager can take a long time to load and the progress is usually displayed in another window (Terminal). I'm adding support for showing a UI inside React Native app for packager's progress when loading a bundle.

This is how it will work:

1. React Native sends request to packager with `Accept: multipart/mixed` header.
2. Packager will detect that header to detect that client supports progress events and will reply with `Content-Type: multipart/mixed`.
3. While building the bundle it will emit chunks with small metadata (like `{progress: 0.3}`). In the end it will send the last chunk with the content of the bundle.
4. RN runtime will be receiving the events, for each progress event it will update the UI. The last chunk will be the actual bundle which will end the download process.

This workflow is totally backwards-compatible -- normally RN doesn't set the `Accept` header.

Reviewed By: mmmulani

Differential Revision: D3845684

fbshipit-source-id: 5b3d2c5a4c6f4718d7e5de060d98f17491e82aba
2016-10-03 18:13:36 -07:00
..
RCTAssert.h Display JS exceptions and stacks in a red box. 2016-06-30 19:43:28 -07:00
RCTAssert.m Display JS exceptions and stacks in a red box. 2016-06-30 19:43:28 -07:00
RCTBatchedBridge.m Make shared new bridge work in wilde/pyml 2016-09-28 14:13:55 -07:00
RCTBridge+Private.h Move batchedbridge start out of init 2016-09-26 16:14:11 -07:00
RCTBridge.h Add support for new ios bridge to FBReactBridgeJSExecutor 2016-09-28 14:13:55 -07:00
RCTBridge.m Add support for new ios bridge to FBReactBridgeJSExecutor 2016-09-28 14:13:55 -07:00
RCTBridgeDelegate.h Sync support for new ios bridge 2016-09-26 16:14:11 -07:00
RCTBridgeMethod.h Support sync method calls in the objc bridge 2016-09-05 07:44:00 -07:00
RCTBridgeModule.h Standardize Error objects for Promises 2016-01-19 12:20:37 -08:00
RCTBundleURLProvider.h Eliminate "packager running predicate" 2016-07-15 05:43:47 -07:00
RCTBundleURLProvider.m Eliminate "packager running predicate" 2016-07-15 05:43:47 -07:00
RCTConvert.h Apple TV support 1: existing Objective C code should compile for tvOS 2016-09-27 06:28:33 -07:00
RCTConvert.m Apple TV support 1: existing Objective C code should compile for tvOS 2016-09-27 06:28:33 -07:00
RCTDefines.h Add RCT_PROFILE define 2016-06-13 04:28:38 -07:00
RCTDisplayLink.h Pull CADisplayLink into a separate file 2016-03-29 19:53:20 -07:00
RCTDisplayLink.m Remove last arg from RCTProfileEnd, make macro's function-like 2016-09-05 11:13:33 -07:00
RCTErrorCustomizer.h Add ability to customize error messages and stacks within the iOS redbox 2016-07-18 11:28:36 -07:00
RCTErrorInfo.h Add ability to customize error messages and stacks within the iOS redbox 2016-07-18 11:28:36 -07:00
RCTErrorInfo.m Add ability to customize error messages and stacks within the iOS redbox 2016-07-18 11:28:36 -07:00
RCTEventDispatcher.h Updated AppState module to use new emitter system 2016-05-23 09:13:37 -07:00
RCTEventDispatcher.m Use new enqueueJSCall method everywhere 2016-08-02 11:14:06 -07:00
RCTFrameUpdate.h Pause JS DisplayLink if nothing to process. 2015-09-29 09:22:10 -07:00
RCTFrameUpdate.m Ran Convert > To Modern Objective C Syntax 2015-08-25 01:08:49 -08:00
RCTImageSource.h Remove deprecated RCTImageSource method 2016-08-23 11:28:42 -07:00
RCTImageSource.m Support bundle argument for image loading 2016-08-31 17:43:49 -07:00
RCTInvalidating.h Remove isValid from RCTInvalidating 2015-08-14 01:57:18 -08:00
RCTJSStackFrame.h Class for JS stack frames instead of dictionaries 2016-07-11 06:13:32 -07:00
RCTJSStackFrame.m Fix crash in RCTJSStackFrame 2016-08-26 09:58:47 -07:00
RCTJavaScriptExecutor.h Add MessageQueue method for executing function and returning its result 2016-07-18 07:13:32 -07:00
RCTJavaScriptLoader.h Remove allowLoadingNonRAMBundles 2016-07-13 16:43:38 -07:00
RCTJavaScriptLoader.m Improve error message when packager is not running 2016-08-02 08:13:57 -07:00
RCTKeyCommands.h Add Shortcut "Double R" to Reload JS in iOS 2016-06-01 03:43:27 -07:00
RCTKeyCommands.m Cleanup warnings 2016-07-12 05:59:12 -07:00
RCTLog.h Provide log source to handler 2015-11-11 06:44:30 -08:00
RCTLog.m Added unit tests for module init 2016-03-01 09:44:37 -08:00
RCTModuleData.h Replaced isMainThread checks with a proper test for main queue 2016-06-06 07:58:36 -07:00
RCTModuleData.mm Simplify ModuleConfig array format 2016-09-23 11:14:10 -07:00
RCTModuleMethod.h Implement Android's dispatchViewManagerCommand interface on iOS 2016-01-06 05:58:37 -08:00
RCTModuleMethod.m Remove last arg from RCTProfileEnd, make macro's function-like 2016-09-05 11:13:33 -07:00
RCTMultipartStreamReader.h Add multipart response stream reader 2016-10-03 18:13:36 -07:00
RCTMultipartStreamReader.m Add multipart response stream reader 2016-10-03 18:13:36 -07:00
RCTNullability.h Replaced RegExp method parser with recursive descent 2015-12-10 10:12:29 -08:00
RCTParserUtils.h Replaced RegExp method parser with recursive descent 2015-12-10 10:12:29 -08:00
RCTParserUtils.m Replaced RegExp method parser with recursive descent 2015-12-10 10:12:29 -08:00
RCTPerformanceLogger.h Refactor measuring native requires 2016-09-09 15:28:44 -07:00
RCTPerformanceLogger.m Refactor measuring native requires 2016-09-09 15:28:44 -07:00
RCTRootView.h remove dead code 2016-02-29 10:09:54 -08:00
RCTRootView.m Remove last arg from RCTProfileEnd, make macro's function-like 2016-09-05 11:13:33 -07:00
RCTRootViewDelegate.h Prevent RCTRootView delegate call 2015-11-13 08:28:28 -08:00
RCTRootViewInternal.h Introduction of RCTRootViewDelegate 2015-10-26 15:41:36 -07:00
RCTTouchEvent.h Set viewTag for RCTTouchEvent to avoid EventID conflict 2016-09-16 16:13:47 -07:00
RCTTouchEvent.m Set viewTag for RCTTouchEvent to avoid EventID conflict 2016-09-16 16:13:47 -07:00
RCTTouchHandler.h API for cancelling RCTTouchHandler 2016-01-21 13:46:52 -08:00
RCTTouchHandler.m Set viewTag for RCTTouchEvent to avoid EventID conflict 2016-09-16 16:13:47 -07:00
RCTURLRequestDelegate.h Refactored networking logic out into RCTDownloadTask 2015-07-23 04:00:31 -08:00
RCTURLRequestHandler.h [ReactNative] Refactor RCTDataManager to support pluggable data source modules (RCTURLRequestHandlers) 2015-06-09 12:27:06 -08:00
RCTUtils.h Apple TV support 1: existing Objective C code should compile for tvOS 2016-09-27 06:28:33 -07:00
RCTUtils.m Apple TV support 1: existing Objective C code should compile for tvOS 2016-09-27 06:28:33 -07:00
RCTWebSocketProxy.h Enable persistent socket between packager and bridge (1/N). 2016-02-16 23:05:36 -08:00
RCTWebSocketProxyDelegate.h Enable persistent socket between packager and bridge (1/N). 2016-02-16 23:05:36 -08:00