> An iPad is fine for writing code, but not capable of compiling/running code.
I mean, hardware-wise, it's totally capable; it's got a pretty powerful CPU in it. It's just the App Store publishing policies that don't want to cooperate.
But there's nothing fundamentally stopping someone from creating a Crouton-like "chroot in a box" environment and publishing it as an XCode project; and nothing stopping you from taking said XCode project and deploying it to your iPad using development provisioning.
There are web inspector apps on the App Store. I use Inspect Browser [1] myself for that purpose.
[1]: https://apps.apple.com/us/app/inspect-browser/id1203594958
I use that. It has a JS console but it doesn't seem to have access to JS on the page like the Chrome console does. If I had Chrome or Safari web developer tools I would only have the clunky text selection to complain about, and I can live with that.
If iOS Safari had the inspector/debugger, or just inspector with live JS console, I would almost never need to use my laptop (which is just Chromebook, but runs full Chrome).