On screen this stuff is pretty easy, but where it can fall down is in print. We had a client a few years ago who printed thousands of full-color, glossy brochures with a QR code. Somebody decided it would look better if it were smaller with less margin. That was an expensive mistake.
When someone prints the page the QR code will be visible, linking back to the original page. Having said that, I think I’ve only printed 2 or 3 pages from the web in the last 12 months… but you never know.
We can use the images.Overlay filter to place a raster image on top of another raster image. We can’t do that with vector files.
As @nfriedli pointed out, monochrome raster images like these are typically 3-10x smaller than SVGs. We’ve got black dots and white dots… single bit color. For a 100x100 image that’s 10,000 bits or 1250 bytes. And that’s before deflating, which reduces the file size another 30%-50%. And the author of the package we’re using, Russ Cox, wasn’t even optimizing for file size when he wrote the library… he was optimizing for speed.
Russ Cox is also the person who designed and implemented (other people have since contributed) the Go Modules system (which backs what we call Hugo Modules). There may be small details in that setup I don’t totally agree about, but it’s a pretty incredible engineering feat for one person. He interened at Google with Jeff Dean (the Chuck Norris of Google) during hist first summer break from college. That summer he implemented Google Code Search – Google recently closed down this index, but the code behind it is in use by others.