
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
react-native-webview2
Advanced tools
This is the `WebView` component in React Native both for Android and iOS, support `auto height` & call js between component and html page, very useful & easily!
This is the WebView or Web component in React Native both for Android and iOS, support auto height & call js (not support on ios) between component and html document, very useful & easily!
This is a JavaScript-only implementation of WebView in React Native, named react-native-webview2 or WebView or Web.
react-native-webview2 can change the height of WebView dynamically when you set the prop source={uri:xxx}(until now not yet support html) if you not set the prop style={height:xxx}, otherwise the height of WebView is fixed.react-native-webview2 also can make you call js in html document or reactnative, if you want to call js in html page from react-native, you just invoke this.web.evalJs("js code...here") from react-native. If you want to call react-native code, you just invoke returnEval("rn code...here") from html page, meanwhile set the prop evalReturn={((r) => {eval(r)}).bind(this)}.react-native-webview2 support all props of WebView in React Native.WebView demo project: https://github.com/greatbsky/react-native-webview2-demo
WebView Demo
WebView Usagenpm install react-native-webview2@latest --saveimport Web from 'react-native-webview2';
<Web
ref={(c) => {this.web = c}}
evalReturn={((r) => {eval(r)}).bind(this)}
source={{uri: 'xxx'}}
style={[styles.web, {minHeight: 300}]}
...other props
/>
WebView configurationspecial props for WebView
evalJs: (not support on ios) handle function if you want to call js in html page from react-native. eg: this.web.evalJs('var t = document.title; alert(t)');evalReturn: require if you need call js fun in react-native from html page. evalReturn={((r) => {eval(r)}).bind(this)}.go: handle function if you need open a new uri. eg: this.web.go('http://xxxxxx');other
returnEval: js function in html page if you want to call js in react-native from html page, eg:returnEval('this.setText("from html page...")'), usually you also need set the prop of component evalReturn={((r) => {eval(r)}).bind(this)}MIT License
FAQs
This is the `WebView` component in React Native both for Android and iOS, support `auto height` & call js between component and html page, very useful & easily!
The npm package react-native-webview2 receives a total of 6 weekly downloads. As such, react-native-webview2 popularity was classified as not popular.
We found that react-native-webview2 demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.