Skip to content

Commit

Permalink
feat: add public init
Browse files Browse the repository at this point in the history
  • Loading branch information
tsuzukihashi committed Jun 2, 2023
1 parent 3b4cef9 commit 80010a1
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions Sources/TsuzuKit/Representable/LinkPresentationView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,13 @@ import LinkPresentation
public struct LinkPresentationView: UIViewRepresentable {
public typealias UIViewType = LPLinkView

let url: URL
@Binding var redraw: Bool
public let url: URL
@Binding public var redraw: Bool

public init(url: URL, redraw: Binding<Bool>) {
self.url = url
self._redraw = redraw
}

public func makeUIView(context: UIViewRepresentableContext<LinkPresentationView>) -> UIViewType {
let view = LPLinkView(url: url)
Expand Down

0 comments on commit 80010a1

Please sign in to comment.