react-native-webview/android
Thibault Malbranche f3bdab5a22
feat(Android/iOS postMessage): refactoring the old postMessage implementation (#303)
fixes #29
fixes #272
fixes #221
fixes #105
fixes #66

BREAKING CHANGE: Communication from webview to react-native has been completely rewritten. React-native-webview will not use or override window.postMessage anymore. Reasons behind these changes can be found throughout so many issues that it made sense to go that way.

Instead of using window.postMessage(data, *), please now use window.ReactNativeWebView.postMessage(data).

Side note: if you wish to keep compatibility with the old version when you upgrade, you can use the injectedJavascript prop to do that:

const injectedJavascript = `(function() {
  window.postMessage = function(data) {
    window.ReactNativeWebView.postMessage(data);
  };
})()`;

Huge thanks to @jordansexton and @KoenLav!
2019-02-01 18:37:28 +01:00
..
src/main feat(Android/iOS postMessage): refactoring the old postMessage implementation (#303) 2019-02-01 18:37:28 +01:00
build.gradle fix(Gradle): Allow kotlinVersion override using ext with gradle.properties (#267) 2019-01-23 01:58:27 +01:00
gradle.properties fix(Gradle): Allow kotlinVersion override using ext with gradle.properties (#267) 2019-01-23 01:58:27 +01:00