From 476397b309fb0180285847c85c3a779f79ebe9d6 Mon Sep 17 00:00:00 2001 From: abolger Date: Thu, 5 Oct 2017 11:16:24 -0400 Subject: [PATCH 1/3] Removing deprecated functionality. --- .npmignore | 2 + package-lock.json | 127 ++++++++++++++++++++++++++++++++ package.json | 74 +++++++++++++------ webview-bridge/index.android.js | 8 +- webview-bridge/index.ios.js | 6 +- 5 files changed, 192 insertions(+), 25 deletions(-) create mode 100644 .npmignore create mode 100644 package-lock.json diff --git a/.npmignore b/.npmignore new file mode 100644 index 00000000..fd4f2b06 --- /dev/null +++ b/.npmignore @@ -0,0 +1,2 @@ +node_modules +.DS_Store diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 00000000..18f1d1d9 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,127 @@ +{ + "name": "react-native-webview-bridge", + "version": "0.33.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "asap": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", + "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=" + }, + "core-js": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-1.2.7.tgz", + "integrity": "sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY=" + }, + "create-react-class": { + "version": "15.6.2", + "resolved": "https://registry.npmjs.org/create-react-class/-/create-react-class-15.6.2.tgz", + "integrity": "sha1-zx7RXxKq1/FO9fLf4F5sQvke8Co=", + "requires": { + "fbjs": "0.8.16", + "loose-envify": "1.3.1", + "object-assign": "4.1.1" + } + }, + "encoding": { + "version": "0.1.12", + "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.12.tgz", + "integrity": "sha1-U4tm8+5izRq1HsMjgp0flIDHS+s=", + "requires": { + "iconv-lite": "0.4.19" + } + }, + "fbjs": { + "version": "0.8.16", + "resolved": "https://registry.npmjs.org/fbjs/-/fbjs-0.8.16.tgz", + "integrity": "sha1-XmdDL1UNxBtXK/VYR7ispk5TN9s=", + "requires": { + "core-js": "1.2.7", + "isomorphic-fetch": "2.2.1", + "loose-envify": "1.3.1", + "object-assign": "4.1.1", + "promise": "7.3.1", + "setimmediate": "1.0.5", + "ua-parser-js": "0.7.14" + } + }, + "iconv-lite": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", + "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==" + }, + "invariant": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.0.tgz", + "integrity": "sha1-yNfoRzZqScwYtiLwWKaJ1IHolfI=", + "requires": { + "loose-envify": "1.3.1" + } + }, + "is-stream": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", + "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=" + }, + "isomorphic-fetch": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/isomorphic-fetch/-/isomorphic-fetch-2.2.1.tgz", + "integrity": "sha1-YRrhrPFPXoH3KVB0coGf6XM1WKk=", + "requires": { + "node-fetch": "1.7.3", + "whatwg-fetch": "2.0.3" + } + }, + "js-tokens": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz", + "integrity": "sha1-mGbfOVECEw449/mWvOtlRDIJwls=" + }, + "loose-envify": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.3.1.tgz", + "integrity": "sha1-0aitM/qc4OcT1l/dCsi3SNR4yEg=", + "requires": { + "js-tokens": "3.0.2" + } + }, + "node-fetch": { + "version": "1.7.3", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.3.tgz", + "integrity": "sha512-NhZ4CsKx7cYm2vSrBAr2PvFOe6sWDf0UYLRqA6svUYg7+/TSfVAu49jYC4BvQ4Sms9SZgdqGBgroqfDhJdTyKQ==", + "requires": { + "encoding": "0.1.12", + "is-stream": "1.1.0" + } + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" + }, + "promise": { + "version": "7.3.1", + "resolved": "https://registry.npmjs.org/promise/-/promise-7.3.1.tgz", + "integrity": "sha512-nolQXZ/4L+bP/UGlkfaIujX9BKxGwmQ9OT4mOt5yvy8iK1h3wqTEJCijzGANTCCl9nWjY41juyAn2K3Q1hLLTg==", + "requires": { + "asap": "2.0.6" + } + }, + "setimmediate": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=" + }, + "ua-parser-js": { + "version": "0.7.14", + "resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-0.7.14.tgz", + "integrity": "sha1-EQ1T+kw/MmwSEpK76skE0uAzh8o=" + }, + "whatwg-fetch": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-2.0.3.tgz", + "integrity": "sha1-nITsLc9oGH/wC8ZOEnS0QhduHIQ=" + } + } +} diff --git a/package.json b/package.json index b15b8d58..9bbbbf94 100644 --- a/package.json +++ b/package.json @@ -1,36 +1,68 @@ { - "name": "react-native-webview-bridge", - "version": "0.33.0", + "_from": "git+https://github.com/alinz/react-native-webview-bridge.git", + "_id": "react-native-webview-bridge@0.33.0", + "_inBundle": false, + "_integrity": "sha1-FGO0lAKW/eKAgh/kgwqicIr6rTI=", + "_location": "/react-native-webview-bridge", + "_phantomChildren": { + "loose-envify": "1.3.1" + }, + "_requested": { + "type": "git", + "raw": "react-native-webview-bridge-updated@git+https://github.com/alinz/react-native-webview-bridge", + "name": "react-native-webview-bridge-updated", + "escapedName": "react-native-webview-bridge-updated", + "rawSpec": "git+https://github.com/alinz/react-native-webview-bridge", + "saveSpec": "git+https://github.com/alinz/react-native-webview-bridge.git", + "fetchSpec": "https://github.com/alinz/react-native-webview-bridge.git", + "gitCommittish": "master" + }, + "_requiredBy": [ + "#USER", + "/" + ], + "_resolved": "git+https://github.com/alinz/react-native-webview-bridge.git#45a330f5a637a6b1df8e6a19e99068ca52642769", + "_spec": "react-native-webview-bridge-updated@git+https://github.com/alinz/react-native-webview-bridge", + "_where": "/Users/adrienne/Code/dani-rewiremed/rewiremed", + "author": { + "name": "Ali Najafizadeh" + }, + "bugs": { + "url": "https://github.com/alinz/react-native-webview-bridge/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "Hunter Medney" + } + ], + "dependencies": { + "create-react-class": "^15.6.2", + "invariant": "2.2.0", + "keymirror": "0.1.1" + }, + "deprecated": false, "description": "React Native WebView Javascript Bridge", - "main": "webview-bridge", "directories": { "example": "example", "lib": "lib" }, - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" - }, - "repository": { - "type": "git", - "url": "git@github.com:alinz/react-native-webview-bridge.git" - }, + "homepage": "https://github.com/alinz/react-native-webview-bridge", "keywords": [ "react-native", "react-component", "ios", "webview-bridge" ], - "author": "Ali Najafizadeh", - "contributors": [ - "Hunter Medney" - ], "license": "MIT", - "bugs": { - "url": "https://github.com/alinz/react-native-webview-bridge/issues" + "main": "webview-bridge", + "name": "react-native-webview-bridge", + "repository": { + "type": "git", + "url": "git+ssh://git@github.com/alinz/react-native-webview-bridge.git" }, - "homepage": "https://github.com/alinz/react-native-webview-bridge", - "dependencies": { - "invariant": "2.2.0", - "keymirror": "0.1.1" - } + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "version": "0.33.0" } diff --git a/webview-bridge/index.android.js b/webview-bridge/index.android.js index bdfe8180..a218251d 100644 --- a/webview-bridge/index.android.js +++ b/webview-bridge/index.android.js @@ -13,6 +13,10 @@ */ 'use strict'; +import PropTypes from 'prop-types'; + +var createReactClass = require('create-react-class'); + var React = require('react'); var ReactNative = require('react-native'); var invariant = require('invariant'); @@ -33,7 +37,7 @@ var { WebViewBridgeManager } } = ReactNative; -var { PropTypes } = React; + var RCT_WEBVIEWBRIDGE_REF = 'webviewbridge'; @@ -48,7 +52,7 @@ var RCTWebViewBridge = requireNativeComponent('RCTWebViewBridge', WebViewBridge) /** * Renders a native WebView. */ -var WebViewBridge = React.createClass({ +var WebViewBridge = createReactClass({ propTypes: { ...RCTWebViewBridge.propTypes, diff --git a/webview-bridge/index.ios.js b/webview-bridge/index.ios.js index b47dc338..a7aab5fc 100644 --- a/webview-bridge/index.ios.js +++ b/webview-bridge/index.ios.js @@ -33,7 +33,9 @@ var { WebViewBridgeManager } } = ReactNative; -var { PropTypes } = React; +import PropTypes from 'prop-types'; + +var createReactClass = require('create-react-class'); var BGWASH = 'rgba(255,255,255,0.8)'; var RCT_WEBVIEWBRIDGE_REF = 'webviewbridge'; @@ -90,7 +92,7 @@ var defaultRenderError = (errorDomain, errorCode, errorDesc) => ( /** * Renders a native WebView. */ -var WebViewBridge = React.createClass({ +var WebViewBridge = createReactClass({ statics: { JSNavigationScheme: JSNavigationScheme, NavigationType: NavigationType, From baed96cd007a04c517a4bf3415e38e262cf885d6 Mon Sep 17 00:00:00 2001 From: abolger Date: Mon, 9 Oct 2017 12:23:11 -0400 Subject: [PATCH 2/3] Revert "Removing deprecated functionality." This reverts commit 476397b309fb0180285847c85c3a779f79ebe9d6. --- .npmignore | 2 - package-lock.json | 127 -------------------------------- package.json | 74 ++++++------------- webview-bridge/index.android.js | 8 +- webview-bridge/index.ios.js | 6 +- 5 files changed, 25 insertions(+), 192 deletions(-) delete mode 100644 .npmignore delete mode 100644 package-lock.json diff --git a/.npmignore b/.npmignore deleted file mode 100644 index fd4f2b06..00000000 --- a/.npmignore +++ /dev/null @@ -1,2 +0,0 @@ -node_modules -.DS_Store diff --git a/package-lock.json b/package-lock.json deleted file mode 100644 index 18f1d1d9..00000000 --- a/package-lock.json +++ /dev/null @@ -1,127 +0,0 @@ -{ - "name": "react-native-webview-bridge", - "version": "0.33.0", - "lockfileVersion": 1, - "requires": true, - "dependencies": { - "asap": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", - "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=" - }, - "core-js": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-1.2.7.tgz", - "integrity": "sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY=" - }, - "create-react-class": { - "version": "15.6.2", - "resolved": "https://registry.npmjs.org/create-react-class/-/create-react-class-15.6.2.tgz", - "integrity": "sha1-zx7RXxKq1/FO9fLf4F5sQvke8Co=", - "requires": { - "fbjs": "0.8.16", - "loose-envify": "1.3.1", - "object-assign": "4.1.1" - } - }, - "encoding": { - "version": "0.1.12", - "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.12.tgz", - "integrity": "sha1-U4tm8+5izRq1HsMjgp0flIDHS+s=", - "requires": { - "iconv-lite": "0.4.19" - } - }, - "fbjs": { - "version": "0.8.16", - "resolved": "https://registry.npmjs.org/fbjs/-/fbjs-0.8.16.tgz", - "integrity": "sha1-XmdDL1UNxBtXK/VYR7ispk5TN9s=", - "requires": { - "core-js": "1.2.7", - "isomorphic-fetch": "2.2.1", - "loose-envify": "1.3.1", - "object-assign": "4.1.1", - "promise": "7.3.1", - "setimmediate": "1.0.5", - "ua-parser-js": "0.7.14" - } - }, - "iconv-lite": { - "version": "0.4.19", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", - "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==" - }, - "invariant": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.0.tgz", - "integrity": "sha1-yNfoRzZqScwYtiLwWKaJ1IHolfI=", - "requires": { - "loose-envify": "1.3.1" - } - }, - "is-stream": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", - "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=" - }, - "isomorphic-fetch": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/isomorphic-fetch/-/isomorphic-fetch-2.2.1.tgz", - "integrity": "sha1-YRrhrPFPXoH3KVB0coGf6XM1WKk=", - "requires": { - "node-fetch": "1.7.3", - "whatwg-fetch": "2.0.3" - } - }, - "js-tokens": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz", - "integrity": "sha1-mGbfOVECEw449/mWvOtlRDIJwls=" - }, - "loose-envify": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.3.1.tgz", - "integrity": "sha1-0aitM/qc4OcT1l/dCsi3SNR4yEg=", - "requires": { - "js-tokens": "3.0.2" - } - }, - "node-fetch": { - "version": "1.7.3", - "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.3.tgz", - "integrity": "sha512-NhZ4CsKx7cYm2vSrBAr2PvFOe6sWDf0UYLRqA6svUYg7+/TSfVAu49jYC4BvQ4Sms9SZgdqGBgroqfDhJdTyKQ==", - "requires": { - "encoding": "0.1.12", - "is-stream": "1.1.0" - } - }, - "object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" - }, - "promise": { - "version": "7.3.1", - "resolved": "https://registry.npmjs.org/promise/-/promise-7.3.1.tgz", - "integrity": "sha512-nolQXZ/4L+bP/UGlkfaIujX9BKxGwmQ9OT4mOt5yvy8iK1h3wqTEJCijzGANTCCl9nWjY41juyAn2K3Q1hLLTg==", - "requires": { - "asap": "2.0.6" - } - }, - "setimmediate": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", - "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=" - }, - "ua-parser-js": { - "version": "0.7.14", - "resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-0.7.14.tgz", - "integrity": "sha1-EQ1T+kw/MmwSEpK76skE0uAzh8o=" - }, - "whatwg-fetch": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-2.0.3.tgz", - "integrity": "sha1-nITsLc9oGH/wC8ZOEnS0QhduHIQ=" - } - } -} diff --git a/package.json b/package.json index 9bbbbf94..b15b8d58 100644 --- a/package.json +++ b/package.json @@ -1,68 +1,36 @@ { - "_from": "git+https://github.com/alinz/react-native-webview-bridge.git", - "_id": "react-native-webview-bridge@0.33.0", - "_inBundle": false, - "_integrity": "sha1-FGO0lAKW/eKAgh/kgwqicIr6rTI=", - "_location": "/react-native-webview-bridge", - "_phantomChildren": { - "loose-envify": "1.3.1" - }, - "_requested": { - "type": "git", - "raw": "react-native-webview-bridge-updated@git+https://github.com/alinz/react-native-webview-bridge", - "name": "react-native-webview-bridge-updated", - "escapedName": "react-native-webview-bridge-updated", - "rawSpec": "git+https://github.com/alinz/react-native-webview-bridge", - "saveSpec": "git+https://github.com/alinz/react-native-webview-bridge.git", - "fetchSpec": "https://github.com/alinz/react-native-webview-bridge.git", - "gitCommittish": "master" - }, - "_requiredBy": [ - "#USER", - "/" - ], - "_resolved": "git+https://github.com/alinz/react-native-webview-bridge.git#45a330f5a637a6b1df8e6a19e99068ca52642769", - "_spec": "react-native-webview-bridge-updated@git+https://github.com/alinz/react-native-webview-bridge", - "_where": "/Users/adrienne/Code/dani-rewiremed/rewiremed", - "author": { - "name": "Ali Najafizadeh" - }, - "bugs": { - "url": "https://github.com/alinz/react-native-webview-bridge/issues" - }, - "bundleDependencies": false, - "contributors": [ - { - "name": "Hunter Medney" - } - ], - "dependencies": { - "create-react-class": "^15.6.2", - "invariant": "2.2.0", - "keymirror": "0.1.1" - }, - "deprecated": false, + "name": "react-native-webview-bridge", + "version": "0.33.0", "description": "React Native WebView Javascript Bridge", + "main": "webview-bridge", "directories": { "example": "example", "lib": "lib" }, - "homepage": "https://github.com/alinz/react-native-webview-bridge", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "repository": { + "type": "git", + "url": "git@github.com:alinz/react-native-webview-bridge.git" + }, "keywords": [ "react-native", "react-component", "ios", "webview-bridge" ], + "author": "Ali Najafizadeh", + "contributors": [ + "Hunter Medney" + ], "license": "MIT", - "main": "webview-bridge", - "name": "react-native-webview-bridge", - "repository": { - "type": "git", - "url": "git+ssh://git@github.com/alinz/react-native-webview-bridge.git" - }, - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" + "bugs": { + "url": "https://github.com/alinz/react-native-webview-bridge/issues" }, - "version": "0.33.0" + "homepage": "https://github.com/alinz/react-native-webview-bridge", + "dependencies": { + "invariant": "2.2.0", + "keymirror": "0.1.1" + } } diff --git a/webview-bridge/index.android.js b/webview-bridge/index.android.js index a218251d..bdfe8180 100644 --- a/webview-bridge/index.android.js +++ b/webview-bridge/index.android.js @@ -13,10 +13,6 @@ */ 'use strict'; -import PropTypes from 'prop-types'; - -var createReactClass = require('create-react-class'); - var React = require('react'); var ReactNative = require('react-native'); var invariant = require('invariant'); @@ -37,7 +33,7 @@ var { WebViewBridgeManager } } = ReactNative; - +var { PropTypes } = React; var RCT_WEBVIEWBRIDGE_REF = 'webviewbridge'; @@ -52,7 +48,7 @@ var RCTWebViewBridge = requireNativeComponent('RCTWebViewBridge', WebViewBridge) /** * Renders a native WebView. */ -var WebViewBridge = createReactClass({ +var WebViewBridge = React.createClass({ propTypes: { ...RCTWebViewBridge.propTypes, diff --git a/webview-bridge/index.ios.js b/webview-bridge/index.ios.js index a7aab5fc..b47dc338 100644 --- a/webview-bridge/index.ios.js +++ b/webview-bridge/index.ios.js @@ -33,9 +33,7 @@ var { WebViewBridgeManager } } = ReactNative; -import PropTypes from 'prop-types'; - -var createReactClass = require('create-react-class'); +var { PropTypes } = React; var BGWASH = 'rgba(255,255,255,0.8)'; var RCT_WEBVIEWBRIDGE_REF = 'webviewbridge'; @@ -92,7 +90,7 @@ var defaultRenderError = (errorDomain, errorCode, errorDesc) => ( /** * Renders a native WebView. */ -var WebViewBridge = createReactClass({ +var WebViewBridge = React.createClass({ statics: { JSNavigationScheme: JSNavigationScheme, NavigationType: NavigationType, From c8b134f559c281a78699d7ca14b5fcadc9a3b5db Mon Sep 17 00:00:00 2001 From: abolger Date: Mon, 9 Oct 2017 12:36:59 -0400 Subject: [PATCH 3/3] Bringing compatibility up to latest React Native 0.49.1 --- package.json | 5 ++++- webview-bridge/index.android.js | 8 ++++++-- webview-bridge/index.ios.js | 6 ++++-- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index b15b8d58..e4669135 100644 --- a/package.json +++ b/package.json @@ -31,6 +31,9 @@ "homepage": "https://github.com/alinz/react-native-webview-bridge", "dependencies": { "invariant": "2.2.0", - "keymirror": "0.1.1" + "keymirror": "0.1.1", + "prop-types": "15.5.10", + "create-react-class": "15.6.2" + } } diff --git a/webview-bridge/index.android.js b/webview-bridge/index.android.js index bdfe8180..a218251d 100644 --- a/webview-bridge/index.android.js +++ b/webview-bridge/index.android.js @@ -13,6 +13,10 @@ */ 'use strict'; +import PropTypes from 'prop-types'; + +var createReactClass = require('create-react-class'); + var React = require('react'); var ReactNative = require('react-native'); var invariant = require('invariant'); @@ -33,7 +37,7 @@ var { WebViewBridgeManager } } = ReactNative; -var { PropTypes } = React; + var RCT_WEBVIEWBRIDGE_REF = 'webviewbridge'; @@ -48,7 +52,7 @@ var RCTWebViewBridge = requireNativeComponent('RCTWebViewBridge', WebViewBridge) /** * Renders a native WebView. */ -var WebViewBridge = React.createClass({ +var WebViewBridge = createReactClass({ propTypes: { ...RCTWebViewBridge.propTypes, diff --git a/webview-bridge/index.ios.js b/webview-bridge/index.ios.js index b47dc338..a7aab5fc 100644 --- a/webview-bridge/index.ios.js +++ b/webview-bridge/index.ios.js @@ -33,7 +33,9 @@ var { WebViewBridgeManager } } = ReactNative; -var { PropTypes } = React; +import PropTypes from 'prop-types'; + +var createReactClass = require('create-react-class'); var BGWASH = 'rgba(255,255,255,0.8)'; var RCT_WEBVIEWBRIDGE_REF = 'webviewbridge'; @@ -90,7 +92,7 @@ var defaultRenderError = (errorDomain, errorCode, errorDesc) => ( /** * Renders a native WebView. */ -var WebViewBridge = React.createClass({ +var WebViewBridge = createReactClass({ statics: { JSNavigationScheme: JSNavigationScheme, NavigationType: NavigationType,