I'm with the author until he says to encode extra information into the URL. If the docs and the site are built well, you should find everything you need while completely ignoring the URL structure.
The latter form clearly presents the possibility of jumping straight to a different version's foo docs, to the docs homepage, etc. I'd consider this a quality of good UX.