Skip to content

Commit a1ce727

Browse files
97chosinteractord
authored andcommitted
feat: Added Initialize LinkItem
1 parent 55f06c6 commit a1ce727

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

Sources/LinkNavigator/Core/BaseComponent/LinkItem.swift

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,16 @@ public struct LinkItem {
2929
encodedItemString = items
3030
}
3131

32+
public init(path: String, items: Codable) {
33+
pathList = [path]
34+
encodedItemString = items.encoded()
35+
}
36+
37+
public init(pathList: [String], items: Codable) {
38+
self.pathList = pathList
39+
encodedItemString = items.encoded()
40+
}
41+
3242
// MARK: Internal
3343

3444
/// An array of strings representing the path list.

0 commit comments

Comments
 (0)