A modern web stack template powered by Golang, Templ, TailwindCSS, Alpine.js, and HTMX.
This project serves as a starter template that helps you quickly bootstrap your development.
Simply replace goath-stack with your own project name, and you’re ready to go.
- 🚀 Golang + Templ: Type-safe template engine with enhanced HTML componentization.
- 🎨 TailwindCSS v4: A utility-first and elegant CSS framework.
- 🌈 DaisyUI: A beautiful, themeable component library built on top of TailwindCSS.
- ⚡ Alpine.js: Lightweight JavaScript for interactivity.
- 🔗 HTMX: Build interactive frontends with minimal JavaScript.
- 🐳 Docker Support: Works for both local development and containerized environments.
go install golang.org/x/tools/cmd/gonew@latestgonew github.com/dachichang/goath-stack-template your-project-namemake initwill init entire project necessary modifies.- Replace the OpenAPI annotations
goath-stackin themain.gowith your own project name.
make runinstalls the required dependencies and uses air for automatic build of the project.- The generated binary will be placed under the
tmpdirectory. - The default port is
3000, but you can adjust it in the.envfile.
make upstarts the entire local development environment using docker compose.- Everything runs fully inside Docker, ensuring a 100% clean environment.
- When you exit the container, all builds and
node_moduleswill not be preserved. - The default port is
8080, but you can adjust it in thedocker-compose.yamlfile. - Use
make logto monitor containers running status and logs. - It is recommended to use Docker for development to keep your local system clean.
make docker-imagewill automatically build the local Docker image, and once completed, it can be executed immediately.make docker-runwill start the image generated bymake docker-image, expose port 3000, and load the.envenvironment variables.- Note: If you are not using the
default port 3000, you will need to adjust both theMakefileand.envto ensure they match.