Author SHA1 Message Date
ahmza 874d665266 Update DECISIONS.md 2026-10-06 09:52:24 +00:00
ahmza ede76f3dbd created simple webserver 2026-10-05 13:22:09 +01:00
5 changed files with 26 additions and 1 deletions
+1
View File
@@ -0,0 +1 @@
*.test
+1 -1
View File
@@ -6,7 +6,7 @@ A file describing tech stack / feature decisions. sort of a change log
| Area | Choice | Reasoning | | Area | Choice | Reasoning |
| ------------- | ----------- | ----------------------------------------------------------------------------------------------------------------------------------------- | | ------------- | ----------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
| Backend | Go | Language I want to learn | | Backend | Go | It's fast. Go compiles to a single native binary, and it compiles fast. It's simple. It's a small language without a ton of feature bloat. It's statically typed. The compiler catches type bugs before your code even runs. Concurrency is built in. Goroutines are very powerful, which is a big reason tools like Docker and Kubernetes are written in Go. |
| Web framework | HTMX | Server-side rendering reduces client-side roundtrip complexity; same API calls happen server-side but feels quicker/lighter on the client | | Web framework | HTMX | Server-side rendering reduces client-side roundtrip complexity; same API calls happen server-side but feels quicker/lighter on the client |
| Frontend | HTML/CSS/JS | Standard building blocks, no framework chosen yet | | Frontend | HTML/CSS/JS | Standard building blocks, no framework chosen yet |
| Database | PostgreSQL | Scales better than SQLite, at the cost of more setup/learning overhead | | Database | PostgreSQL | Scales better than SQLite, at the cost of more setup/learning overhead |
Executable
BIN
View File
Binary file not shown.
+21
View File
@@ -0,0 +1,21 @@
package main
import (
"io"
"log"
"net/http"
)
func healthHandler(w http.ResponseWriter, r *http.Request) {
io.WriteString(w, "ok")
}
func routes(internalMux *http.ServeMux) {
internalMux.HandleFunc("/health", healthHandler)
}
func main() {
backslashMux := http.NewServeMux()
routes(backslashMux)
log.Fatal(http.ListenAndServe(":8080", backslashMux))
}
+3
View File
@@ -0,0 +1,3 @@
module tea.ahmza.com/ahmza.com/backslash
go 1.27