We should differentiate between Xcode the ide and Xcode tools, which are just git, clang, etc. The tools aren’t apple’s product.
In Linux they would have been separate packages, but I don’t think the App Store has dependencies so how else are they going to get the required packages installed for their ide.