From 70ac51f9b6dcf6d8923c6e152239acc3696c7206 Mon Sep 17 00:00:00 2001 From: fangkyi02 <30390014+fangkyi03@users.noreply.github.com> Date: Thu, 10 Jul 2025 11:37:03 +0800 Subject: [PATCH] Update WebView.harmony.tsx MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修复页面跳转导致的崩溃问题 --- src/WebView.harmony.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/WebView.harmony.tsx b/src/WebView.harmony.tsx index c4ae5d2464..fe15e780db 100644 --- a/src/WebView.harmony.tsx +++ b/src/WebView.harmony.tsx @@ -111,9 +111,9 @@ const WebViewComponent = forwardRef<{}, IOSWebViewProps & { scalesPageToFit: boo > | null>(null); const onShouldStartLoadWithRequestCallback = useCallback( - (shouldStart: boolean, _url: string, lockIdentifier = 0) => { + async (shouldStart: boolean, _url: string, lockIdentifier = 0) => { RNCWebViewModule.shouldStartLoadWithLockIdentifier( - shouldStart, + await shouldStart, lockIdentifier ); }, @@ -327,4 +327,4 @@ const isFileUploadSupported: () => Promise = async () => true; const WebView = Object.assign(WebViewComponent, { isFileUploadSupported }); -export default WebView; \ No newline at end of file +export default WebView;