From 1e4d9d4897edc868b136140b88ad62fc1d987ca4 Mon Sep 17 00:00:00 2001 From: Philipp von Weitershausen Date: Wed, 25 May 2016 05:21:36 -0700 Subject: [PATCH] Expose Systrace from the 'react-native' package Summary: This allows React Native apps to instrument their own code via Systrace.measureMethod() and the like. **Test Plan:** Used require('react-native').Systrace in my own app successfully to instrument my own code. Closes https://github.com/facebook/react-native/pull/7734 Differential Revision: D3346222 Pulled By: javache fbshipit-source-id: 08ffc781a1187db89c6e9a0714d644dbc485724c --- Libraries/react-native/react-native.js | 1 + Libraries/react-native/react-native.js.flow | 1 + 2 files changed, 2 insertions(+) diff --git a/Libraries/react-native/react-native.js b/Libraries/react-native/react-native.js index 6200bd42d..bd5e082a0 100644 --- a/Libraries/react-native/react-native.js +++ b/Libraries/react-native/react-native.js @@ -100,6 +100,7 @@ const ReactNative = { get Settings() { return require('Settings'); }, get StatusBarIOS() { return require('StatusBarIOS'); }, get StyleSheet() { return require('StyleSheet'); }, + get Systrace() { return require('Systrace'); }, get TimePickerAndroid() { return require('TimePickerAndroid'); }, get UIManager() { return require('UIManager'); }, get Vibration() { return require('Vibration'); }, diff --git a/Libraries/react-native/react-native.js.flow b/Libraries/react-native/react-native.js.flow index 066736dac..74c306f2c 100644 --- a/Libraries/react-native/react-native.js.flow +++ b/Libraries/react-native/react-native.js.flow @@ -98,6 +98,7 @@ var ReactNative = Object.assign(Object.create(require('ReactNative')), { Settings: require('Settings'), StatusBarIOS: require('StatusBarIOS'), StyleSheet: require('StyleSheet'), + Systrace: require('Systrace'), TimePickerAndroid: require('TimePickerAndroid'), UIManager: require('UIManager'), Vibration: require('Vibration'),