react-native-webview-bootpay 13.13.47 → 13.13.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +37 -0
- package/android/src/main/java/kr/co/bootpay/webview/BPCWebView.java +16 -2
- package/android/src/main/java/kr/co/bootpay/webview/BPCWebViewModuleImpl.java +54 -0
- package/android/src/newarch/kr/co/bootpay/webview/BPCWebViewModule.java +10 -0
- package/android/src/oldarch/kr/co/bootpay/webview/BPCWebViewModule.java +10 -0
- package/apple/BPCWKProcessPoolManager.h +13 -0
- package/apple/BPCWKProcessPoolManager.m +43 -0
- package/apple/BPCWebViewModule.mm +20 -0
- package/lib/NativeBPCWebViewModule.d.ts +10 -0
- package/package.json +29 -29
- package/src/NativeBPCWebViewModule.ts +10 -0
package/README.md
CHANGED
|
@@ -80,3 +80,40 @@ This readme is available in:
|
|
|
80
80
|
- [Brazilian portuguese](docs/README.portuguese.md)
|
|
81
81
|
- [French](docs/README.french.md)
|
|
82
82
|
- [Italian](docs/README.italian.md)
|
|
83
|
+
|
|
84
|
+
---
|
|
85
|
+
|
|
86
|
+
## Bootpay WebView 프리워밍 (iOS)
|
|
87
|
+
|
|
88
|
+
iOS의 WKWebView는 첫 로딩 시 GPU, Networking, WebContent 프로세스 초기화로 4-6초 지연이 발생할 수 있습니다.
|
|
89
|
+
|
|
90
|
+
**Bootpay React Native WebView는 모듈 로드 시 자동으로 프리워밍이 시작됩니다.** 별도의 설정 없이도 첫 결제 화면 로딩 속도가 개선됩니다.
|
|
91
|
+
|
|
92
|
+
### 수동 호출 (선택사항)
|
|
93
|
+
|
|
94
|
+
특별한 타이밍에 프리워밍을 시작하고 싶다면 수동으로 호출할 수 있습니다:
|
|
95
|
+
|
|
96
|
+
```javascript
|
|
97
|
+
import { NativeModules } from 'react-native';
|
|
98
|
+
|
|
99
|
+
const { BPCWebViewModule } = NativeModules;
|
|
100
|
+
|
|
101
|
+
// 기본 호출 (0.1초 딜레이)
|
|
102
|
+
BPCWebViewModule.warmUp();
|
|
103
|
+
|
|
104
|
+
// 커스텀 딜레이로 호출 (UI 버벅임 시)
|
|
105
|
+
BPCWebViewModule.warmUpWithDelay(0.5);
|
|
106
|
+
|
|
107
|
+
// 메모리 부족 시 리소스 해제
|
|
108
|
+
BPCWebViewModule.releaseWarmUp();
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
### API
|
|
112
|
+
|
|
113
|
+
| 메서드 | 설명 |
|
|
114
|
+
|--------|------|
|
|
115
|
+
| `warmUp()` | WebView 프로세스 미리 초기화 (자동 실행됨) |
|
|
116
|
+
| `warmUpWithDelay(delay)` | 커스텀 딜레이(초)로 프리워밍 |
|
|
117
|
+
| `releaseWarmUp()` | 프리워밍 리소스 해제 |
|
|
118
|
+
|
|
119
|
+
> **참고**: Android에서는 이 기능이 no-op으로 동작합니다 (iOS 전용).
|
|
@@ -302,9 +302,17 @@ public class BPCWebView extends WebView implements LifecycleEventListener {
|
|
|
302
302
|
|
|
303
303
|
private void injectJavascriptObject() {
|
|
304
304
|
if (getSettings().getJavaScriptEnabled()) {
|
|
305
|
+
// iOS와 동일하게 postMessage 함수를 명시적으로 정의
|
|
306
|
+
// WebViewCompat.addWebMessageListener가 주입한 원본 postMessage를 보존하면서
|
|
307
|
+
// injectedObjectJson 등 추가 기능 제공
|
|
305
308
|
String js = "(function(){\n" +
|
|
309
|
+
" var existing = window." + JAVASCRIPT_INTERFACE + ";\n" +
|
|
310
|
+
" var originalPostMessage = existing ? existing.postMessage : null;\n" +
|
|
306
311
|
" window." + JAVASCRIPT_INTERFACE + " = window." + JAVASCRIPT_INTERFACE + " || {};\n" +
|
|
307
312
|
" window." + JAVASCRIPT_INTERFACE + ".injectedObjectJson = function () { return " + (injectedJavaScriptObject == null ? null : ("`" + injectedJavaScriptObject + "`")) + "; };\n" +
|
|
313
|
+
" if (originalPostMessage) {\n" +
|
|
314
|
+
" window." + JAVASCRIPT_INTERFACE + ".postMessage = originalPostMessage;\n" +
|
|
315
|
+
" }\n" +
|
|
308
316
|
"})();";
|
|
309
317
|
evaluateJavascriptWithFallback(js);
|
|
310
318
|
}
|
|
@@ -471,9 +479,15 @@ public class BPCWebView extends WebView implements LifecycleEventListener {
|
|
|
471
479
|
* - window[JAVASCRIPT_INTERFACE].postMessage
|
|
472
480
|
*/
|
|
473
481
|
@JavascriptInterface
|
|
474
|
-
public void postMessage(String message) {
|
|
482
|
+
public void postMessage(final String message) {
|
|
475
483
|
if (mWebView.getMessagingEnabled()) {
|
|
476
|
-
|
|
484
|
+
// WebView methods must be called on the main (UI) thread
|
|
485
|
+
mWebView.post(new Runnable() {
|
|
486
|
+
@Override
|
|
487
|
+
public void run() {
|
|
488
|
+
mWebView.onMessage(message, mWebView.getUrl());
|
|
489
|
+
}
|
|
490
|
+
});
|
|
477
491
|
} else {
|
|
478
492
|
FLog.w(TAG, "ReactNativeWebView.postMessage method was called but messaging is disabled. Pass an onMessage handler to the WebView.");
|
|
479
493
|
}
|
|
@@ -34,6 +34,11 @@ import com.facebook.react.module.annotations.ReactModule;
|
|
|
34
34
|
import com.facebook.react.modules.core.PermissionAwareActivity;
|
|
35
35
|
import com.facebook.react.modules.core.PermissionListener;
|
|
36
36
|
|
|
37
|
+
import android.webkit.CookieManager;
|
|
38
|
+
import android.webkit.WebView;
|
|
39
|
+
import android.os.Handler;
|
|
40
|
+
import android.os.Looper;
|
|
41
|
+
|
|
37
42
|
import java.io.File;
|
|
38
43
|
import java.io.IOException;
|
|
39
44
|
import java.lang.SecurityException;
|
|
@@ -51,6 +56,10 @@ public class BPCWebViewModuleImpl implements ActivityEventListener {
|
|
|
51
56
|
public static final int PICKER_LEGACY = 3;
|
|
52
57
|
public static final int FILE_DOWNLOAD_PERMISSION_REQUEST = 1;
|
|
53
58
|
|
|
59
|
+
// WarmUp을 위한 프리워밍된 WebView
|
|
60
|
+
private static WebView sPrewarmedWebView;
|
|
61
|
+
private static boolean sIsWarmedUp = false;
|
|
62
|
+
|
|
54
63
|
final private ReactApplicationContext mContext;
|
|
55
64
|
|
|
56
65
|
private DownloadManager.Request mDownloadRequest;
|
|
@@ -65,6 +74,51 @@ public class BPCWebViewModuleImpl implements ActivityEventListener {
|
|
|
65
74
|
context.addActivityEventListener(this);
|
|
66
75
|
}
|
|
67
76
|
|
|
77
|
+
/**
|
|
78
|
+
* WebView 프로세스를 미리 초기화하여 첫 결제 화면 로딩 속도를 개선합니다.
|
|
79
|
+
* Application의 onCreate 또는 적절한 시점에 호출하세요.
|
|
80
|
+
*
|
|
81
|
+
* Chromium 엔진 초기화에 200-300ms가 소요되므로, 이 메서드를 미리 호출하면
|
|
82
|
+
* 실제 결제 시 즉시 WebView가 표시됩니다.
|
|
83
|
+
*/
|
|
84
|
+
public void warmUp() {
|
|
85
|
+
if (sIsWarmedUp) {
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
new Handler(Looper.getMainLooper()).post(() -> {
|
|
90
|
+
try {
|
|
91
|
+
// CookieManager 초기화로 Chromium 엔진 로드 (thread-safe)
|
|
92
|
+
CookieManager.getInstance();
|
|
93
|
+
|
|
94
|
+
// 프리워밍용 WebView 생성
|
|
95
|
+
if (sPrewarmedWebView == null && mContext != null) {
|
|
96
|
+
sPrewarmedWebView = new WebView(mContext);
|
|
97
|
+
// 빈 HTML을 로드하여 WebContent 프로세스 초기화
|
|
98
|
+
sPrewarmedWebView.loadDataWithBaseURL(null, "", "text/html", "UTF-8", null);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
sIsWarmedUp = true;
|
|
102
|
+
} catch (Exception e) {
|
|
103
|
+
Log.w("BPCWebViewModule", "Failed to warm up WebView", e);
|
|
104
|
+
}
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* 프리워밍된 WebView 리소스를 해제합니다.
|
|
110
|
+
* 메모리가 부족할 때 호출할 수 있습니다.
|
|
111
|
+
*/
|
|
112
|
+
public void releaseWarmUp() {
|
|
113
|
+
new Handler(Looper.getMainLooper()).post(() -> {
|
|
114
|
+
if (sPrewarmedWebView != null) {
|
|
115
|
+
sPrewarmedWebView.destroy();
|
|
116
|
+
sPrewarmedWebView = null;
|
|
117
|
+
}
|
|
118
|
+
sIsWarmedUp = false;
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
|
|
68
122
|
@Override
|
|
69
123
|
public void onActivityResult(Activity activity, int requestCode, int resultCode, Intent data) {
|
|
70
124
|
if (mFilePathCallback == null && mFilePathCallbackLegacy == null) {
|
|
@@ -29,6 +29,16 @@ public class BPCWebViewModule extends NativeBPCWebViewModuleSpec {
|
|
|
29
29
|
mBPCWebViewModuleImpl.shouldStartLoadWithLockIdentifier(shouldStart, lockIdentifier);
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
+
@Override
|
|
33
|
+
public void warmUp() {
|
|
34
|
+
mBPCWebViewModuleImpl.warmUp();
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
@Override
|
|
38
|
+
public void releaseWarmUp() {
|
|
39
|
+
mBPCWebViewModuleImpl.releaseWarmUp();
|
|
40
|
+
}
|
|
41
|
+
|
|
32
42
|
public void startPhotoPickerIntent(ValueCallback<Uri> filePathCallback, String acceptType) {
|
|
33
43
|
mBPCWebViewModuleImpl.startPhotoPickerIntent(acceptType, filePathCallback);
|
|
34
44
|
}
|
|
@@ -31,6 +31,16 @@ public class BPCWebViewModule extends ReactContextBaseJavaModule {
|
|
|
31
31
|
mBPCWebViewModuleImpl.shouldStartLoadWithLockIdentifier(shouldStart, lockIdentifier);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
+
@ReactMethod
|
|
35
|
+
public void warmUp() {
|
|
36
|
+
mBPCWebViewModuleImpl.warmUp();
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
@ReactMethod
|
|
40
|
+
public void releaseWarmUp() {
|
|
41
|
+
mBPCWebViewModuleImpl.releaseWarmUp();
|
|
42
|
+
}
|
|
43
|
+
|
|
34
44
|
public void startPhotoPickerIntent(ValueCallback<Uri> filePathCallback, String acceptType) {
|
|
35
45
|
mBPCWebViewModuleImpl.startPhotoPickerIntent(acceptType, filePathCallback);
|
|
36
46
|
}
|
|
@@ -12,4 +12,17 @@
|
|
|
12
12
|
+ (instancetype) sharedManager;
|
|
13
13
|
- (WKProcessPool *)sharedProcessPool;
|
|
14
14
|
|
|
15
|
+
/// WebView 프로세스를 미리 초기화하여 첫 결제 화면 로딩 속도를 개선합니다.
|
|
16
|
+
/// @param delay 프리워밍 시작 전 대기 시간 (초). 기본값 0.1초. UI가 느려지면 0.5~1.0으로 늘려보세요.
|
|
17
|
+
- (void)warmUpWithDelay:(NSTimeInterval)delay;
|
|
18
|
+
|
|
19
|
+
/// 기본 딜레이(0.1초)로 프리워밍을 시작합니다.
|
|
20
|
+
- (void)warmUp;
|
|
21
|
+
|
|
22
|
+
/// 프리워밍된 WebView 리소스를 해제합니다.
|
|
23
|
+
- (void)releaseWarmUp;
|
|
24
|
+
|
|
25
|
+
/// 프리워밍 완료 여부를 확인합니다.
|
|
26
|
+
@property (nonatomic, readonly) BOOL isWarmedUp;
|
|
27
|
+
|
|
15
28
|
@end
|
|
@@ -10,9 +10,14 @@
|
|
|
10
10
|
|
|
11
11
|
@interface BPCWKProcessPoolManager() {
|
|
12
12
|
WKProcessPool *_sharedProcessPool;
|
|
13
|
+
WKWebView *_prewarmedWebView;
|
|
14
|
+
BOOL _isWarmUpComplete;
|
|
13
15
|
}
|
|
14
16
|
@end
|
|
15
17
|
|
|
18
|
+
/// 프리워밍용 최소 HTML (GPU/WebContent/Networking 프로세스 초기화 트리거)
|
|
19
|
+
static NSString *const kWarmUpHTML = @"<!DOCTYPE html><html><head><meta charset=\"utf-8\"><meta name=\"viewport\" content=\"width=device-width,initial-scale=1\"></head><body><canvas id=\"c\" width=\"1\" height=\"1\"></canvas><script>var c=document.getElementById('c').getContext('2d');c.fillRect(0,0,1,1);fetch('https://webview.bootpay.co.kr/health',{mode:'no-cors'}).catch(function(){});</script></body></html>";
|
|
20
|
+
|
|
16
21
|
@implementation BPCWKProcessPoolManager
|
|
17
22
|
|
|
18
23
|
+ (id) sharedManager {
|
|
@@ -32,5 +37,43 @@
|
|
|
32
37
|
return _sharedProcessPool;
|
|
33
38
|
}
|
|
34
39
|
|
|
40
|
+
- (void)warmUp {
|
|
41
|
+
[self warmUpWithDelay:0.1];
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
- (void)warmUpWithDelay:(NSTimeInterval)delay {
|
|
45
|
+
if (_prewarmedWebView != nil) return;
|
|
46
|
+
|
|
47
|
+
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(delay * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
|
|
48
|
+
if (self->_prewarmedWebView == nil) {
|
|
49
|
+
WKWebViewConfiguration *config = [[WKWebViewConfiguration alloc] init];
|
|
50
|
+
config.processPool = [self sharedProcessPool];
|
|
51
|
+
|
|
52
|
+
// WebView 생성 - GPU/WebContent 프로세스 시작
|
|
53
|
+
self->_prewarmedWebView = [[WKWebView alloc] initWithFrame:CGRectMake(0, 0, 1, 1) configuration:config];
|
|
54
|
+
|
|
55
|
+
// 실제 렌더링 + 네트워크 요청으로 모든 프로세스 초기화
|
|
56
|
+
[self->_prewarmedWebView loadHTMLString:kWarmUpHTML baseURL:[NSURL URLWithString:@"https://webview.bootpay.co.kr"]];
|
|
57
|
+
|
|
58
|
+
self->_isWarmUpComplete = YES;
|
|
59
|
+
|
|
60
|
+
#ifdef DEBUG
|
|
61
|
+
NSLog(@"[Bootpay] warmUp started - WebView processes initializing...");
|
|
62
|
+
#endif
|
|
63
|
+
}
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
- (void)releaseWarmUp {
|
|
68
|
+
dispatch_async(dispatch_get_main_queue(), ^{
|
|
69
|
+
self->_prewarmedWebView = nil;
|
|
70
|
+
self->_isWarmUpComplete = NO;
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
- (BOOL)isWarmedUp {
|
|
75
|
+
return _isWarmUpComplete && _prewarmedWebView != nil;
|
|
76
|
+
}
|
|
77
|
+
|
|
35
78
|
@end
|
|
36
79
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
#import "BPCWebViewModule.h"
|
|
2
2
|
|
|
3
3
|
#import "BPCWebViewDecisionManager.h"
|
|
4
|
+
#import "BPCWKProcessPoolManager.h"
|
|
4
5
|
|
|
5
6
|
#ifdef RCT_NEW_ARCH_ENABLED
|
|
6
7
|
#import <React/RCTFabricComponentsPlugins.h>
|
|
@@ -10,6 +11,25 @@
|
|
|
10
11
|
|
|
11
12
|
RCT_EXPORT_MODULE(BPCWebViewModule)
|
|
12
13
|
|
|
14
|
+
// 모듈 로드 시 자동으로 WebView 프리워밍 시작
|
|
15
|
+
+ (void)load {
|
|
16
|
+
dispatch_async(dispatch_get_main_queue(), ^{
|
|
17
|
+
[[BPCWKProcessPoolManager sharedManager] warmUp];
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
RCT_EXPORT_METHOD(warmUp) {
|
|
22
|
+
[[BPCWKProcessPoolManager sharedManager] warmUp];
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
RCT_EXPORT_METHOD(warmUpWithDelay:(double)delay) {
|
|
26
|
+
[[BPCWKProcessPoolManager sharedManager] warmUpWithDelay:delay];
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
RCT_EXPORT_METHOD(releaseWarmUp) {
|
|
30
|
+
[[BPCWKProcessPoolManager sharedManager] releaseWarmUp];
|
|
31
|
+
}
|
|
32
|
+
|
|
13
33
|
RCT_EXPORT_METHOD(isFileUploadSupported:(RCTPromiseResolveBlock)resolve reject:(RCTPromiseRejectBlock)reject) {
|
|
14
34
|
if (resolve) {
|
|
15
35
|
resolve(@(YES));
|
|
@@ -3,6 +3,16 @@ import { Double } from 'react-native/Libraries/Types/CodegenTypes';
|
|
|
3
3
|
export interface Spec extends TurboModule {
|
|
4
4
|
isFileUploadSupported(): Promise<boolean>;
|
|
5
5
|
shouldStartLoadWithLockIdentifier(shouldStart: boolean, lockIdentifier: Double): void;
|
|
6
|
+
/**
|
|
7
|
+
* WebView 프로세스를 미리 초기화하여 첫 결제 화면 로딩 속도를 개선합니다.
|
|
8
|
+
* 앱 시작 시 또는 결제 화면 진입 전에 호출하세요.
|
|
9
|
+
*/
|
|
10
|
+
warmUp(): void;
|
|
11
|
+
/**
|
|
12
|
+
* 프리워밍된 WebView 리소스를 해제합니다.
|
|
13
|
+
* 메모리가 부족할 때 호출할 수 있습니다.
|
|
14
|
+
*/
|
|
15
|
+
releaseWarmUp(): void;
|
|
6
16
|
}
|
|
7
17
|
declare const _default: Spec;
|
|
8
18
|
export default _default;
|
package/package.json
CHANGED
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"Thibault Malbranche <malbranche.thibault@gmail.com>"
|
|
11
11
|
],
|
|
12
12
|
"license": "MIT",
|
|
13
|
-
"version": "13.13.
|
|
14
|
-
"homepage": "https://github.com/react-native-webview
|
|
13
|
+
"version": "13.13.49",
|
|
14
|
+
"homepage": "https://github.com/bootpay/react-native-webview-bootpay#readme",
|
|
15
15
|
"scripts": {
|
|
16
16
|
"android": "react-native run-android",
|
|
17
17
|
"ios": "react-native run-ios",
|
|
@@ -41,38 +41,38 @@
|
|
|
41
41
|
"invariant": "2.2.4"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"@babel/cli": "^7.
|
|
45
|
-
"@babel/core": "^7.
|
|
46
|
-
"@babel/runtime": "^7.
|
|
47
|
-
"@callstack/react-native-visionos": "0.
|
|
48
|
-
"@react-native/babel-preset": "0.
|
|
49
|
-
"@react-native/eslint-config": "0.
|
|
50
|
-
"@react-native/metro-config": "0.
|
|
51
|
-
"@react-native/typescript-config": "0.
|
|
52
|
-
"@rnx-kit/metro-config": "
|
|
53
|
-
"@semantic-release/git": "
|
|
54
|
-
"@types/invariant": "^2.2.
|
|
55
|
-
"@types/jest": "^29.5.
|
|
56
|
-
"@types/react": "18.
|
|
57
|
-
"@types/selenium-webdriver": "4.
|
|
58
|
-
"appium": "
|
|
59
|
-
"eslint": "8.57.
|
|
60
|
-
"jest": "^29.
|
|
61
|
-
"prettier": "
|
|
62
|
-
"react": "18.
|
|
63
|
-
"react-native": "0.
|
|
64
|
-
"react-native-macos": "0.
|
|
65
|
-
"react-native-test-app": "3.7
|
|
66
|
-
"react-native-windows": "0.
|
|
44
|
+
"@babel/cli": "^7.26.0",
|
|
45
|
+
"@babel/core": "^7.26.0",
|
|
46
|
+
"@babel/runtime": "^7.26.0",
|
|
47
|
+
"@callstack/react-native-visionos": "0.76.7",
|
|
48
|
+
"@react-native/babel-preset": "0.76.7",
|
|
49
|
+
"@react-native/eslint-config": "0.76.7",
|
|
50
|
+
"@react-native/metro-config": "0.76.7",
|
|
51
|
+
"@react-native/typescript-config": "0.76.7",
|
|
52
|
+
"@rnx-kit/metro-config": "2.2.0",
|
|
53
|
+
"@semantic-release/git": "10.0.1",
|
|
54
|
+
"@types/invariant": "^2.2.37",
|
|
55
|
+
"@types/jest": "^29.5.14",
|
|
56
|
+
"@types/react": "18.3.18",
|
|
57
|
+
"@types/selenium-webdriver": "4.1.28",
|
|
58
|
+
"appium": "2.15.0",
|
|
59
|
+
"eslint": "8.57.1",
|
|
60
|
+
"jest": "^29.7.0",
|
|
61
|
+
"prettier": "3.4.2",
|
|
62
|
+
"react": "18.3.1",
|
|
63
|
+
"react-native": "0.76.7",
|
|
64
|
+
"react-native-macos": "0.76.7",
|
|
65
|
+
"react-native-test-app": "3.11.7",
|
|
66
|
+
"react-native-windows": "0.76.7",
|
|
67
67
|
"selenium-appium": "1.0.2",
|
|
68
|
-
"selenium-webdriver": "4.
|
|
69
|
-
"semantic-release": "
|
|
70
|
-
"typescript": "5.
|
|
68
|
+
"selenium-webdriver": "4.27.0",
|
|
69
|
+
"semantic-release": "24.2.1",
|
|
70
|
+
"typescript": "5.6.3",
|
|
71
71
|
"winappdriver": "^0.0.7"
|
|
72
72
|
},
|
|
73
73
|
"repository": {
|
|
74
74
|
"type": "git",
|
|
75
|
-
"url": "https://github.com/react-native-webview
|
|
75
|
+
"url": "https://github.com/bootpay/react-native-webview-bootpay.git"
|
|
76
76
|
},
|
|
77
77
|
"files": [
|
|
78
78
|
"android/src",
|
|
@@ -8,6 +8,16 @@ export interface Spec extends TurboModule {
|
|
|
8
8
|
shouldStart: boolean,
|
|
9
9
|
lockIdentifier: Double
|
|
10
10
|
): void;
|
|
11
|
+
/**
|
|
12
|
+
* WebView 프로세스를 미리 초기화하여 첫 결제 화면 로딩 속도를 개선합니다.
|
|
13
|
+
* 앱 시작 시 또는 결제 화면 진입 전에 호출하세요.
|
|
14
|
+
*/
|
|
15
|
+
warmUp(): void;
|
|
16
|
+
/**
|
|
17
|
+
* 프리워밍된 WebView 리소스를 해제합니다.
|
|
18
|
+
* 메모리가 부족할 때 호출할 수 있습니다.
|
|
19
|
+
*/
|
|
20
|
+
releaseWarmUp(): void;
|
|
11
21
|
}
|
|
12
22
|
|
|
13
23
|
export default TurboModuleRegistry.getEnforcing<Spec>('BPCWebViewModule');
|