You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-06-12 22:57:38 +02:00
Fixing issue with webview so that WebKit rendering can be used
This commit is contained in:
@ -124,7 +124,7 @@ class NoteBodyViewer extends Component {
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
</head>
|
||||
<body>
|
||||
` + html + `
|
||||
@ -166,11 +166,14 @@ class NoteBodyViewer extends Component {
|
||||
|
||||
// Note: useWebKit={false} is needed to go around this bug:
|
||||
// https://github.com/react-native-community/react-native-webview/issues/376
|
||||
// However, if we add the <meta> tag as described there, it is no longer necessary and WebKit can be used!
|
||||
// https://github.com/react-native-community/react-native-webview/issues/312#issuecomment-501991406
|
||||
// TODO: remove no longer used scalesPageToFit
|
||||
|
||||
return (
|
||||
<View style={style}>
|
||||
<WebView
|
||||
useWebKit={false}
|
||||
useWebKit={true}
|
||||
scalesPageToFit={Platform.OS !== 'ios'}
|
||||
style={webViewStyle}
|
||||
source={source}
|
||||
|
Reference in New Issue
Block a user