The project uses Go build tags to switch between serving static assets from the local filesystem (development) or from within the compiled binary (production).
Development Mode
Use the -tags=dev build tag. This utilizes static_dev.go to provide an HTTP handler that serves assets directly from the filesystem without embedding them. This allows for faster iteration without re-compiling the binary for every asset change.
Production Mode
Use the -tags=prod build tag (or omit build tags entirely). This utilizes static_prod.go to embed the static assets directly into the binary using hashfs. This ensures the binary is self-contained and ready for deployment.
go build -tags=dev .
# or
go build -tags=prod .