Why do we need to buy so many devices anyway? Why can't I just plug my iPad or iPhone into a dumb dock with a laptop screen and its own storage and battery, and use the CPU and GPU from the phone/ipad?
I don't need VSCode, Docker, or node.js on my phone. I don't want all the clones of the various repositories I'm working on on my phone. Even the best phones lack the RAM, high capacity drives, and video card my computer has. Nor does it have a keyboard or trackpad.
If your phone is good enough to take care of your day to day computing, you can probably get by with an inexpensive all-in-one computer and save the headache of docking.
You'd be surprised how many people would like exactly this, interestingly. There are certainly enough to quite literally pay real money for a somewhat lousy facsimile of the real thing; I know from experience.
Then what is the point in docking at all? Now you have to keep track of what's on the dock and what's on the phone. Plus, by the time you integrate all this into a dock, you basically have something that costs as much as an inexpensive PC, so why bother?
You'll need something to connect all those dock components together so you don't have to run several cables to the phone. Something like a motherboard. So you'll have a full computer sans a cpu.
The Surface Book is exactly this: A (x64 Windows) tablet with a laptop dock that contains a stronger GPU and battery.
One problem is that people expect the CPU power of a laptop, which requires much more power and cooling than the typical tablet. As a consequence in tablet mode a Surface Book has about two hours of battery life.
So far: different architectures. But with this announcement it would make running macOS on a future (or even current) iPad quite feasible, so your kind of dock might become true soon. Apple's new magic iPad keyboards use a lot of weight to balance the heavy screen - might as well make that a battery.
When looking for IDEs or tooling on iOS I still have not found anything remotely professionally usable... (I mean Visual Studio + Reshaper like, not VS Code...) but perhaps somebody could enlighten me...
Because a general purpose device is not good business sense for a company that sells devices. The more they can artificially specialize each thing, the more things you need to buy, and the more money they make. This is a much larger phenomenon than just Apple, or even computers.
An iPhone is a general purpose device compared to an iPod. But maybe Apple has lost the willingness to cannibalise its own sales for the sake of creating stunning new product categories.
You can plug in a USB dock into a lot of Android phones, and if you get a DisplayLink dock, you can add 2-3 monitors. Keyboard, mouse, sound, Ethernet all work with it too.