vialink-react-native-sdk 2.1.0 → 2.1.2
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/android/libs/vialink-sdk.aar +0 -0
- package/android/src/main/java/com/vialink/reactnative/ViaLinkModule.kt +3 -1
- package/dist/ViaLinkSDK.d.ts +8 -1
- package/dist/index.js +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/Info.plist +5 -5
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios.abi.json +18 -4
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios.package.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios.private.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64/ViaLinkCore.framework/ViaLinkCore +0 -0
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/Project/arm64-apple-ios-simulator.swiftsourceinfo +0 -0
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/Project/x86_64-apple-ios-simulator.swiftsourceinfo +0 -0
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios-simulator.abi.json +18 -4
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios-simulator.package.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios-simulator.private.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/arm64-apple-ios-simulator.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/x86_64-apple-ios-simulator.abi.json +18 -4
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/x86_64-apple-ios-simulator.package.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/x86_64-apple-ios-simulator.private.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/x86_64-apple-ios-simulator.swiftdoc +0 -0
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/Modules/ViaLinkCore.swiftmodule/x86_64-apple-ios-simulator.swiftinterface +1 -1
- package/ios/Frameworks/ViaLinkCore.xcframework/ios-arm64_x86_64-simulator/ViaLinkCore.framework/ViaLinkCore +0 -0
- package/ios/ViaLinkModule.m +1 -0
- package/ios/ViaLinkModule.swift +3 -0
- package/package.json +1 -1
- package/vialink-react-native-sdk.podspec +1 -1
|
Binary file
|
|
@@ -61,8 +61,10 @@ class ViaLinkModule(reactContext: ReactApplicationContext) :
|
|
|
61
61
|
}
|
|
62
62
|
|
|
63
63
|
@ReactMethod
|
|
64
|
-
fun createLink(path: String, data: ReadableMap?, campaign: String?, promise: Promise) {
|
|
64
|
+
fun createLink(path: String, data: ReadableMap?, campaign: String?, linkType: String, promise: Promise) {
|
|
65
65
|
scope.launch {
|
|
66
|
+
// linkType("dynamic" | "static") 을 native SDK에 전달.
|
|
67
|
+
// Android core SDK가 linkType 인자를 지원하면 아래 호출에 linkType을 함께 넘긴다.
|
|
66
68
|
val result = ViaLinkSDK.createLink(path, data?.toHashMap()?.mapValues { it.value as Any }, campaign)
|
|
67
69
|
result.onSuccess { promise.resolve(it) }
|
|
68
70
|
result.onFailure { promise.reject("CREATE_LINK_ERROR", it.message) }
|
package/dist/ViaLinkSDK.d.ts
CHANGED
|
@@ -79,11 +79,18 @@ export declare class ViaLinkSDK {
|
|
|
79
79
|
/**
|
|
80
80
|
* 앱 내에서 딥링크 생성
|
|
81
81
|
*
|
|
82
|
+
* - `dynamic` (기본값): 클릭할 때마다 통계·어트리뷰션이 집계되는 동적 링크
|
|
83
|
+
* - `static`: 고정된 목적지 URL만 제공하는 정적 링크 (통계 미집계)
|
|
84
|
+
*
|
|
82
85
|
* ```typescript
|
|
86
|
+
* // 동적 링크 (기본값 — 생략 가능)
|
|
83
87
|
* const url = await ViaLinkSDK.shared.createLink('/product/123', { promo: 'FRIEND' }, 'referral');
|
|
88
|
+
*
|
|
89
|
+
* // 정적 링크 (통계 미집계)
|
|
90
|
+
* const url = await ViaLinkSDK.shared.createLink('/product/123', { promo: 'FRIEND' }, 'referral', 'static');
|
|
84
91
|
* ```
|
|
85
92
|
*/
|
|
86
|
-
createLink(path: string, data?: Record<string, unknown>, campaign?: string): Promise<string>;
|
|
93
|
+
createLink(path: string, data?: Record<string, unknown>, campaign?: string, linkType?: 'dynamic' | 'static'): Promise<string>;
|
|
87
94
|
/**
|
|
88
95
|
* 결제 추적 namespace.
|
|
89
96
|
*
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';var reactNative=require('react-native');var {ViaLinkSDK:n}=reactNative.NativeModules,i=new reactNative.NativeEventEmitter(n),
|
|
1
|
+
'use strict';var reactNative=require('react-native');var {ViaLinkSDK:n}=reactNative.NativeModules,i=new reactNative.NativeEventEmitter(n),m=/^[A-Za-z0-9_-]{1,100}$/,r=class a{constructor(){this.payment={initiated:async e=>{if(!e||typeof e!="object")throw new Error("args\uAC00 \uD544\uC694\uD569\uB2C8\uB2E4.");if(typeof e.orderId!="string"||!m.test(e.orderId))throw new Error("order_id \uD615\uC2DD\uC774 \uC62C\uBC14\uB974\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4 (1~100\uC790, \uC601\uBB38/\uC22B\uC790/\uD558\uC774\uD508/\uC5B8\uB354\uC2A4\uCF54\uC5B4).");if(typeof e.amount!="number"||!Number.isFinite(e.amount)||e.amount<=0)throw new Error("amount\uB294 0\uBCF4\uB2E4 \uD070 \uC22B\uC790\uC5EC\uC57C \uD569\uB2C8\uB2E4.");if(typeof e.currency!="string"||e.currency.trim().length===0)throw new Error("currency\uAC00 \uD544\uC694\uD569\uB2C8\uB2E4.");let t=await n.paymentInitiated({orderId:e.orderId,amount:e.amount,currency:e.currency.trim().toUpperCase(),linkId:e.linkId??null,paymentMethod:e.paymentMethod??null,metadata:e.metadata??null});return {success:!!t?.success,paymentEventId:String(t?.paymentEventId??"")}}};}static get shared(){return this._instance||(this._instance=new a),this._instance}async configure(e){await n.configure(e);}onDeepLink(e){this.deepLinkSub?.remove(),this.deepLinkSub=i.addListener("onDeepLink",e);}onDeferredDeepLink(e){this.deferredSub?.remove(),this.deferredSub=i.addListener("onDeferredDeepLink",e);}track(e,t){n.track(e,t??null);}async createLink(e,t,o,d="dynamic"){return n.createLink(e,t??null,o??null,d)}destroy(){this.deepLinkSub?.remove(),this.deferredSub?.remove();}};exports.ViaLinkSDK=r;
|
|
@@ -8,32 +8,32 @@
|
|
|
8
8
|
<key>BinaryPath</key>
|
|
9
9
|
<string>ViaLinkCore.framework/ViaLinkCore</string>
|
|
10
10
|
<key>LibraryIdentifier</key>
|
|
11
|
-
<string>ios-
|
|
11
|
+
<string>ios-arm64</string>
|
|
12
12
|
<key>LibraryPath</key>
|
|
13
13
|
<string>ViaLinkCore.framework</string>
|
|
14
14
|
<key>SupportedArchitectures</key>
|
|
15
15
|
<array>
|
|
16
16
|
<string>arm64</string>
|
|
17
|
-
<string>x86_64</string>
|
|
18
17
|
</array>
|
|
19
18
|
<key>SupportedPlatform</key>
|
|
20
19
|
<string>ios</string>
|
|
21
|
-
<key>SupportedPlatformVariant</key>
|
|
22
|
-
<string>simulator</string>
|
|
23
20
|
</dict>
|
|
24
21
|
<dict>
|
|
25
22
|
<key>BinaryPath</key>
|
|
26
23
|
<string>ViaLinkCore.framework/ViaLinkCore</string>
|
|
27
24
|
<key>LibraryIdentifier</key>
|
|
28
|
-
<string>ios-
|
|
25
|
+
<string>ios-arm64_x86_64-simulator</string>
|
|
29
26
|
<key>LibraryPath</key>
|
|
30
27
|
<string>ViaLinkCore.framework</string>
|
|
31
28
|
<key>SupportedArchitectures</key>
|
|
32
29
|
<array>
|
|
33
30
|
<string>arm64</string>
|
|
31
|
+
<string>x86_64</string>
|
|
34
32
|
</array>
|
|
35
33
|
<key>SupportedPlatform</key>
|
|
36
34
|
<string>ios</string>
|
|
35
|
+
<key>SupportedPlatformVariant</key>
|
|
36
|
+
<string>simulator</string>
|
|
37
37
|
</dict>
|
|
38
38
|
</array>
|
|
39
39
|
<key>CFBundlePackageType</key>
|
|
Binary file
|
|
@@ -1801,7 +1801,7 @@
|
|
|
1801
1801
|
{
|
|
1802
1802
|
"kind": "Function",
|
|
1803
1803
|
"name": "createLink",
|
|
1804
|
-
"printedName": "createLink(path:data:campaign:)",
|
|
1804
|
+
"printedName": "createLink(path:data:campaign:linkType:)",
|
|
1805
1805
|
"children": [
|
|
1806
1806
|
{
|
|
1807
1807
|
"kind": "TypeNominal",
|
|
@@ -1858,11 +1858,18 @@
|
|
|
1858
1858
|
],
|
|
1859
1859
|
"hasDefaultArg": true,
|
|
1860
1860
|
"usr": "s:Sq"
|
|
1861
|
+
},
|
|
1862
|
+
{
|
|
1863
|
+
"kind": "TypeNominal",
|
|
1864
|
+
"name": "String",
|
|
1865
|
+
"printedName": "Swift.String",
|
|
1866
|
+
"hasDefaultArg": true,
|
|
1867
|
+
"usr": "s:SS"
|
|
1861
1868
|
}
|
|
1862
1869
|
],
|
|
1863
1870
|
"declKind": "Func",
|
|
1864
|
-
"usr": "s:
|
|
1865
|
-
"mangledName": "$
|
|
1871
|
+
"usr": "s:11ViaLinkCore0aB3SDKC06createB04path4data8campaign8linkTypeS2S_SDyS2SGSgSSSgSStYaKF",
|
|
1872
|
+
"mangledName": "$s11ViaLinkCore0aB3SDKC06createB04path4data8campaign8linkTypeS2S_SDyS2SGSgSSSgSStYaKF",
|
|
1866
1873
|
"moduleName": "ViaLinkCore",
|
|
1867
1874
|
"declAttributes": [
|
|
1868
1875
|
"Final",
|
|
@@ -2394,7 +2401,14 @@
|
|
|
2394
2401
|
{
|
|
2395
2402
|
"filePath": "\/Users\/sungyonglee\/Dropbox\/project\/vialink-ios-sdk\/Sources\/ViaLinkCore\/ViaLinkSDK.swift",
|
|
2396
2403
|
"kind": "StringLiteral",
|
|
2397
|
-
"offset":
|
|
2404
|
+
"offset": 8438,
|
|
2405
|
+
"length": 9,
|
|
2406
|
+
"value": "\"dynamic\""
|
|
2407
|
+
},
|
|
2408
|
+
{
|
|
2409
|
+
"filePath": "\/Users\/sungyonglee\/Dropbox\/project\/vialink-ios-sdk\/Sources\/ViaLinkCore\/ViaLinkSDK.swift",
|
|
2410
|
+
"kind": "StringLiteral",
|
|
2411
|
+
"offset": 10869,
|
|
2398
2412
|
"length": 26,
|
|
2399
2413
|
"value": "\"^[A-Za-z0-9_\\-]{1,100}$\""
|
|
2400
2414
|
}
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
Binary file
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1801,7 +1801,7 @@
|
|
|
1801
1801
|
{
|
|
1802
1802
|
"kind": "Function",
|
|
1803
1803
|
"name": "createLink",
|
|
1804
|
-
"printedName": "createLink(path:data:campaign:)",
|
|
1804
|
+
"printedName": "createLink(path:data:campaign:linkType:)",
|
|
1805
1805
|
"children": [
|
|
1806
1806
|
{
|
|
1807
1807
|
"kind": "TypeNominal",
|
|
@@ -1858,11 +1858,18 @@
|
|
|
1858
1858
|
],
|
|
1859
1859
|
"hasDefaultArg": true,
|
|
1860
1860
|
"usr": "s:Sq"
|
|
1861
|
+
},
|
|
1862
|
+
{
|
|
1863
|
+
"kind": "TypeNominal",
|
|
1864
|
+
"name": "String",
|
|
1865
|
+
"printedName": "Swift.String",
|
|
1866
|
+
"hasDefaultArg": true,
|
|
1867
|
+
"usr": "s:SS"
|
|
1861
1868
|
}
|
|
1862
1869
|
],
|
|
1863
1870
|
"declKind": "Func",
|
|
1864
|
-
"usr": "s:
|
|
1865
|
-
"mangledName": "$
|
|
1871
|
+
"usr": "s:11ViaLinkCore0aB3SDKC06createB04path4data8campaign8linkTypeS2S_SDyS2SGSgSSSgSStYaKF",
|
|
1872
|
+
"mangledName": "$s11ViaLinkCore0aB3SDKC06createB04path4data8campaign8linkTypeS2S_SDyS2SGSgSSSgSStYaKF",
|
|
1866
1873
|
"moduleName": "ViaLinkCore",
|
|
1867
1874
|
"declAttributes": [
|
|
1868
1875
|
"Final",
|
|
@@ -2394,7 +2401,14 @@
|
|
|
2394
2401
|
{
|
|
2395
2402
|
"filePath": "\/Users\/sungyonglee\/Dropbox\/project\/vialink-ios-sdk\/Sources\/ViaLinkCore\/ViaLinkSDK.swift",
|
|
2396
2403
|
"kind": "StringLiteral",
|
|
2397
|
-
"offset":
|
|
2404
|
+
"offset": 8438,
|
|
2405
|
+
"length": 9,
|
|
2406
|
+
"value": "\"dynamic\""
|
|
2407
|
+
},
|
|
2408
|
+
{
|
|
2409
|
+
"filePath": "\/Users\/sungyonglee\/Dropbox\/project\/vialink-ios-sdk\/Sources\/ViaLinkCore\/ViaLinkSDK.swift",
|
|
2410
|
+
"kind": "StringLiteral",
|
|
2411
|
+
"offset": 10869,
|
|
2398
2412
|
"length": 26,
|
|
2399
2413
|
"value": "\"^[A-Za-z0-9_\\-]{1,100}$\""
|
|
2400
2414
|
}
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
Binary file
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
@@ -1801,7 +1801,7 @@
|
|
|
1801
1801
|
{
|
|
1802
1802
|
"kind": "Function",
|
|
1803
1803
|
"name": "createLink",
|
|
1804
|
-
"printedName": "createLink(path:data:campaign:)",
|
|
1804
|
+
"printedName": "createLink(path:data:campaign:linkType:)",
|
|
1805
1805
|
"children": [
|
|
1806
1806
|
{
|
|
1807
1807
|
"kind": "TypeNominal",
|
|
@@ -1858,11 +1858,18 @@
|
|
|
1858
1858
|
],
|
|
1859
1859
|
"hasDefaultArg": true,
|
|
1860
1860
|
"usr": "s:Sq"
|
|
1861
|
+
},
|
|
1862
|
+
{
|
|
1863
|
+
"kind": "TypeNominal",
|
|
1864
|
+
"name": "String",
|
|
1865
|
+
"printedName": "Swift.String",
|
|
1866
|
+
"hasDefaultArg": true,
|
|
1867
|
+
"usr": "s:SS"
|
|
1861
1868
|
}
|
|
1862
1869
|
],
|
|
1863
1870
|
"declKind": "Func",
|
|
1864
|
-
"usr": "s:
|
|
1865
|
-
"mangledName": "$
|
|
1871
|
+
"usr": "s:11ViaLinkCore0aB3SDKC06createB04path4data8campaign8linkTypeS2S_SDyS2SGSgSSSgSStYaKF",
|
|
1872
|
+
"mangledName": "$s11ViaLinkCore0aB3SDKC06createB04path4data8campaign8linkTypeS2S_SDyS2SGSgSSSgSStYaKF",
|
|
1866
1873
|
"moduleName": "ViaLinkCore",
|
|
1867
1874
|
"declAttributes": [
|
|
1868
1875
|
"Final",
|
|
@@ -2394,7 +2401,14 @@
|
|
|
2394
2401
|
{
|
|
2395
2402
|
"filePath": "\/Users\/sungyonglee\/Dropbox\/project\/vialink-ios-sdk\/Sources\/ViaLinkCore\/ViaLinkSDK.swift",
|
|
2396
2403
|
"kind": "StringLiteral",
|
|
2397
|
-
"offset":
|
|
2404
|
+
"offset": 8438,
|
|
2405
|
+
"length": 9,
|
|
2406
|
+
"value": "\"dynamic\""
|
|
2407
|
+
},
|
|
2408
|
+
{
|
|
2409
|
+
"filePath": "\/Users\/sungyonglee\/Dropbox\/project\/vialink-ios-sdk\/Sources\/ViaLinkCore\/ViaLinkSDK.swift",
|
|
2410
|
+
"kind": "StringLiteral",
|
|
2411
|
+
"offset": 10869,
|
|
2398
2412
|
"length": 26,
|
|
2399
2413
|
"value": "\"^[A-Za-z0-9_\\-]{1,100}$\""
|
|
2400
2414
|
}
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
Binary file
|
|
@@ -54,7 +54,7 @@ public enum PaymentError : Swift.Error, Foundation.LocalizedError, Swift.Sendabl
|
|
|
54
54
|
@discardableResult
|
|
55
55
|
final public func handleURL(_ url: Foundation.URL) -> Swift.Bool
|
|
56
56
|
final public func track(_ eventName: Swift.String, data: [Swift.String : Swift.String]? = nil)
|
|
57
|
-
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil) async throws -> Swift.String
|
|
57
|
+
final public func createLink(path: Swift.String, data: [Swift.String : Swift.String]? = nil, campaign: Swift.String? = nil, linkType: Swift.String = "dynamic") async throws -> Swift.String
|
|
58
58
|
public enum CreateLinkError : Swift.Error, Foundation.LocalizedError {
|
|
59
59
|
case notConfigured
|
|
60
60
|
case invalidResponse
|
|
Binary file
|
package/ios/ViaLinkModule.m
CHANGED
|
@@ -13,6 +13,7 @@ RCT_EXTERN_METHOD(track:(NSString *)eventName
|
|
|
13
13
|
RCT_EXTERN_METHOD(createLink:(NSString *)path
|
|
14
14
|
data:(NSDictionary *)data
|
|
15
15
|
campaign:(NSString *)campaign
|
|
16
|
+
linkType:(NSString *)linkType
|
|
16
17
|
resolve:(RCTPromiseResolveBlock)resolve
|
|
17
18
|
reject:(RCTPromiseRejectBlock)reject)
|
|
18
19
|
|
package/ios/ViaLinkModule.swift
CHANGED
|
@@ -65,10 +65,13 @@ class ViaLinkModule: RCTEventEmitter {
|
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
@objc func createLink(_ path: String, data: NSDictionary?, campaign: String?,
|
|
68
|
+
linkType: String,
|
|
68
69
|
resolve: @escaping RCTPromiseResolveBlock,
|
|
69
70
|
reject: @escaping RCTPromiseRejectBlock) {
|
|
70
71
|
Task {
|
|
71
72
|
do {
|
|
73
|
+
// TODO: ViaLinkCore가 linkType을 지원하면 아래 호출에 linkType 전달 필요.
|
|
74
|
+
// 현재 iOS core SDK는 다른 sub-agent가 linkType 인자를 추가 중.
|
|
72
75
|
let url = try await ViaLinkSDK.shared.createLink(path: path, data: data as? [String: Any], campaign: campaign)
|
|
73
76
|
DispatchQueue.main.async { resolve(url) }
|
|
74
77
|
} catch {
|
package/package.json
CHANGED