I have a file called 404.html under themes/<my-theme>/layouts/ but running hugo doesn’t result in a 404.html under /public/. Shouldn’t it? The docs are unclear on whether custom 404 pages are possible for themes but I’ve seen them used in other themes in the same way.
Apparently there were issues with 404 page generation in earlier versions (here and here) but I am on version 0.70.0 so it should be solved.
Thanks for the reply. Knowing that it should work helped me narrow the issue down and I have now solved it.
I should have tried this before, but just running hugodoes generate the page. What I was doing until now was just running hugo server -D, which, in my defense, has updated my page properly this far.