Build Websites with Hugo: Code in chapter two won't run

This solved the problem for me as well. My comment was at the end of the file.

FWIW, the code still ran correctly even with the formatting (indenting) of the index.html file being slightly different than that shown.

Thanks for finding the solution.