Skip to content
This repository was archived by the owner on Feb 9, 2026. It is now read-only.

Commit b3bbc6a

Browse files
committed
Refactor/cleanup
1 parent 11c6368 commit b3bbc6a

11 files changed

Lines changed: 35 additions & 2 deletions

File tree

File renamed without changes.

ios/Ldk.swift

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class Ldk: NSObject {
3232
let filter = LdkFilter()
3333
let broadcaster = LdkBroadcaster()
3434
let logger = LdkLogger()
35-
//TODO set these fees from the JS code
35+
//TODO set these fees from the JS code. They should be able to be updated live.
3636
let feeEstimator = LdkFeeEstimator(high: 1000, normal: 500, low: 100)
3737
let persister = LdkPersister()
3838

@@ -44,6 +44,16 @@ class Ldk: NSObject {
4444
persister: persister
4545
)
4646

47+
let _ = ChannelManager(
48+
fee_est: feeEstimator,
49+
chain_monitor: Watch(),
50+
tx_broadcaster: broadcaster,
51+
logger: logger,
52+
keys_manager: KeysInterface(),
53+
config: UserConfig(),
54+
params: ChainParameters(network_arg: LDKNetwork_Bitcoin, best_block_arg: BestBlock(block_hash: [], height: 0))
55+
)
56+
4757
resolve("Chain monitor started")
4858
}
4959
}

ios/Ldk.xcodeproj/project.pbxproj

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
/* Begin PBXFileReference section */
2727
134814201AA4EA6300B7C361 /* libLdk.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libLdk.a; sourceTree = BUILT_PRODUCTS_DIR; };
2828
962C8074282A8ADF0070AF84 /* LDKFramework.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; path = LDKFramework.xcframework; sourceTree = "<group>"; };
29+
962C808D282BAF9F0070AF84 /* Classes */ = {isa = PBXFileReference; lastKnownFileType = folder; path = Classes; sourceTree = "<group>"; };
2930
B3E7B5891CC2AC0600A0062D /* Ldk.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Ldk.m; sourceTree = "<group>"; };
3031
F4FF95D5245B92E700C19C63 /* Ldk-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Ldk-Bridging-Header.h"; sourceTree = "<group>"; };
3132
F4FF95D6245B92E800C19C63 /* Ldk.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Ldk.swift; sourceTree = "<group>"; };
@@ -57,6 +58,7 @@
5758
962C8074282A8ADF0070AF84 /* LDKFramework.xcframework */,
5859
F4FF95D6245B92E800C19C63 /* Ldk.swift */,
5960
B3E7B5891CC2AC0600A0062D /* Ldk.m */,
61+
962C808D282BAF9F0070AF84 /* Classes */,
6062
F4FF95D5245B92E700C19C63 /* Ldk-Bridging-Header.h */,
6163
134814211AA4EA7D00B7C361 /* Products */,
6264
);
Binary file not shown.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"lint": "yarn run lint:ts",
2525
"lint:ts": "eslint . --ext .ts,.tsx --fix",
2626
"prepublish": "yarn lint && yarn run build && npm --no-git-tag-version version patch",
27-
"dev:save-native-updates": "cp example/node_modules/@synonymdev/react-native-ldk/ios/*.{m,swift} ./ios",
27+
"dev:save-native-updates": "cp example/node_modules/@synonymdev/react-native-ldk/ios/*.{m,swift} ./ios && cp example/node_modules/@synonymdev/react-native-ldk/ios/Classes/*.swift ./ios/Classes/",
2828
"dev:update-example-dist": "yarn build && cp -R dist example/node_modules/@synonymdev/react-native-ldk",
2929
"dev:example": "yarn dev:save-native-updates && yarn dev:update-example-dist"
3030
},

0 commit comments

Comments
 (0)