Static is a package for generating static websites from any Go web app that uses net/http.
Building static websites with existing frameworks like middleman is easy, but large websites can be slow. hugo is a popular option if you need to convert content using templates, but not if you have a go web app that you want to make static.
static helps you use build static websites that are dynamically generated from sources like RSS feeds, databases, APIs, etc by calling each handler registered and saving the output as files.
Call Build with a http.Handler, a string of paths to build to static files, and a callback for printing progress and errors which are communicated via events. The event handler can be nil but it’s the only way you’ll find out if there’s an error building a path.