I would like to change the background color of a SwiftUI text editor on macOS. Is there a variant for the code below (used for iOS) to work for NSTextField instead of UITextView?
Thanks.
Thanks.
Code Block struct ContentView: View { @State var text = "" init() { UITextView.appearance().backgroundColor = .clear } var body: some View { TextEditor(text: text) .background(Color.red) } }