Developers can switch to a different platform, but the problem is that their customers won't switch. The customers for boutique indie apps simply do not exist on Linux. And they don't exist on Windows to the extent that they exist on the Mac. The Mac has always been by far the best platform to find customers for boutique indie apps, long before Mac code signing existed, and that equation hasn't changed even though Apple is now getting worse and locking down the Mac.
In general, I find the idea strange that developers can simply avoid being dependent on Apple. Look at two of the largest corporations in the world: Google and Facebook. They are themselves platforms. Google has its own mobile OS, Android. And yet... these companies still have big problems with Apple. They still need iOS apps, they still have to go through App Store review, etc.
The world is such that it's extremely difficult for anyone to avoid being dependent in some way on the BigCos. If you think the web is independent, just consider Flash-based web sites. Not so independent anymore, eh? Turns out Google and Apple also control the web browsers. Consider physical product producers and Amazon. And look at how Parler was simultaneously deplatformed by everyone. These BigCos are the elephants in the room, you can't ignore them.