Do you mean Swift? Or perhaps you mean iOS development since you mention SwiftUI?
I can't recall why it's necessary, but the first step in our developer onboarding README is "Install XCode, even though we don't use it"
FWIW our team has found JetBrains pretty fantastic for Swift. An important caveat of that being that we make a database product that runs on linux -- not a MacOS / iOS app that would benefit from all the special features of XCode. My guess is if that's your jam, XCode is the only high-productivity game in town.
[0] https://developer.apple.com/tutorials/swiftui/creating-a-mac...