How will the host build files?
As we covered in Chapters 1 and 2, 11ty creates HTML files from layouts, includes, pages, and data. To do this, the 11ty package needs to be run via a command-line interface. In this chapter, we’ll cover how to run the build process manually to acquire files suitable to upload to a server, but there are better ways to handle this via a build process. A build process sees when changes have been made to the production code, runs 11ty, and uploads the built files to the proper place on a server.
Many static site hosts—such as Netlify, which we’ll cover later in this chapter—have this built in. When selecting a platform, make sure they allow the installation of packages from npm, as that is what is required to run 11ty. Beyond that, most of these platforms will often charge for overages of build minutes—minutes spent building your site on their deployment infrastructure. For many small-to-medium sites, this won’...