Commit 76997a61 authored by cawfree's avatar cawfree

Updated UIManager import for the latest version of react-native.

parent 941edfe2
{ {
"name": "gl-react-native", "name": "gl-react-native",
"version": "2.60.0", "version": "2.60.1",
"description": "OpenGL bindings for react-native to implement complex effects over images and components, in the descriptive VDOM paradigm", "description": "OpenGL bindings for react-native to implement complex effects over images and components, in the descriptive VDOM paradigm",
"repository": { "repository": {
"type": "git", "type": "git",
...@@ -20,7 +20,8 @@ ...@@ -20,7 +20,8 @@
"license": "MIT", "license": "MIT",
"peerDependencies": { "peerDependencies": {
"gl-react": "^2.2.4", "gl-react": "^2.2.4",
"react-native": "*" "react-native": "^0.60.5",
"react": "^16.8.6"
}, },
"dependencies": { "dependencies": {
"invariant": "2.2.0" "invariant": "2.2.0"
......
import invariant from "invariant"; import invariant from "invariant";
import {NativeModules} from "react-native"; import {UIManager, NativeModules} from "react-native";
const {UIManager} = NativeModules;
const GLCanvas = UIManager.getViewManagerConfig('GLCanvas'); const GLCanvas = UIManager.getViewManagerConfig('GLCanvas');
invariant(GLCanvas, invariant(GLCanvas,
`gl-react-native: the native module is not available. `gl-react-native: the native module is not available.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment