TM: trimming down module dependencies when getting NativeModules
Summary: For now, do `require('NativeModules')` instead of `import {NativeModules} from 'react-native'`. Reviewed By: mdvacca Differential Revision: D13934066 fbshipit-source-id: 5188b11428a4dca8cecd1934e593d89a6e3fde2e
This commit is contained in:
parent
05f35c296d
commit
1bbb69355c
|
@ -10,9 +10,10 @@
|
|||
|
||||
'use strict';
|
||||
|
||||
const NativeModules = require('NativeModules');
|
||||
|
||||
import type {TurboModule} from 'RCTExport';
|
||||
import invariant from 'invariant';
|
||||
import {NativeModules} from 'react-native';
|
||||
|
||||
// TODO
|
||||
function get<T: TurboModule>(name: string): ?T {
|
||||
|
|
Loading…
Reference in New Issue