Not being able to show "code" or "screenshots" is not the fault of the prospective employee (as you "oh so subtly" implied with your last sentence).
The point here is not what you share, but that you have something to share and can present it in a manner that's compelling to your prospective employer. In some cases, that might be nothing more than a well-written, detailed description of what you developed. In others, a picture is worth a thousand words and can a preferable format for somebody who isn't a great writer.
And finally, while I wouldn't be so naive as to argue that "engineering" equals "working on public-facing applications", engineers should consider the risks of roles that do not enable them to work on systems that are "visible" or "close to the money". Obviously, there are some industries and specializations that provide lucrative opportunities that don't do this, so there are exceptions. Not every young engineer, however, can realistically count on being able to build a decades-long career in these industries/roles.
I agree with this
> If you have absolutely nothing that you can share (code, screenshots, a URL, a "case study") with a prospective employer, it's not the prospective employer that has a problem.
I disagree with this. If you require this to be true, you've instantly excluded everyone's experience in either government (particularly defense), or industry when you work on internal services. There's a huge number of enterprise developers at my current company who will never be able to show you their work because they're all internal applications. Maybe a "case study" would work, but you have to be real careful of not to cover anything that doesn't fall into the trade secret category.
A "portfolio" does not have to, and should not, consist of side projects. Don't have any real code that you are allowed to share? Obviously, many employers won't hire engineers without reviewing existing code or having you engage in a coding exercise, but here's an idea: take a bunch of screenshots of public-facing applications/functionality you've built for your current and/or past employers. With WordPress and a $25 portfolio theme, you can have a decent-looking showcase of your work product up and running in a matter of hours.
If you have absolutely nothing that you can share (code, screenshots, a URL, a "case study") with a prospective employer, it's not the prospective employer that has a problem.