Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ React Native comes with [WebView](http://facebook.github.io/react-native/docs/we

### Install

1. Install from npm (note the postfix in the package name): `npm install react-native-wkwebview-reborn`
2. run `react-native link react-native-wkwebview-reborn`
1. Install from npm (note the postfix in the package name): `npm install react-native-wkwebview-reborn react-native-webview`
2. run `cd ios && pod install`

**Manual alternative**

Expand Down
2 changes: 1 addition & 1 deletion WKWebView.android.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

import {
WebView,
} from 'react-native';
} from 'react-native-webview';

export default WebView;
14 changes: 8 additions & 6 deletions ios/RCTWKWebView/CRAWKWebView.m
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,17 @@

#import <objc/runtime.h>

NSString *const RCTJSNavigationScheme = @"react-js-navigation";

// runtime trick to remove WKWebView keyboard default toolbar
// see: http://stackoverflow.com/questions/19033292/ios-7-uiwebview-keyboard-issue/19042279#19042279
@interface _SwizzleHelperWK : NSObject @end
@implementation _SwizzleHelperWK
-(id)inputAccessoryView
{
return nil;
}
@end
// @implementation _SwizzleHelperWK
// -(id)inputAccessoryView
// {
// return nil;
// }
// @end

@interface CRAWKWebView () <WKNavigationDelegate, RCTAutoInsetsProtocol, WKScriptMessageHandler, WKUIDelegate, UIScrollViewDelegate>

Expand Down
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@
"name": "react-native-wkwebview-reborn",
"optionalDependencies": {},
"peerDependencies": {
"react": "*",
"react-native": ">= 0.59.0",
"react-native-webview": "^5.4.0",
"prop-types": "^15.6.0"
},
"pre-push#master": [
Expand Down