With the Source Code Reader app its easy to view the source code of a site directly on your iPhone or iPad. You can do this in the app or directly in Safari with the built-in Safari extension.
The app supports dark mode, adjustable font sizes, text search and multiple windows - all available in the Safari extension as well.