Skip to content

Commit 15045a9

Browse files
authored
Merge pull request #7 from darrarski/main
Add missing delegate function (iOS)
2 parents 58e17dd + 7ca0e4b commit 15045a9

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

Sources/CodeEditor/UXCodeTextViewRepresentable.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,12 @@ struct UXCodeTextViewRepresentable : UXViewRepresentable {
9494
parent.source.wrappedValue = textView.string
9595
}
9696

97+
#if os(iOS)
98+
public func textViewDidChange(_ textView: UITextView) {
99+
parent.source.wrappedValue = textView.string
100+
}
101+
#endif
102+
97103
var allowCopy: Bool {
98104
return parent.flags.contains(.selectable)
99105
|| parent.flags.contains(.editable)

0 commit comments

Comments
 (0)