package main import ( "fmt" "net/http" ) func main() { fmt.Println("Starting server on :8000!") handle := Handle{} handle.New() handle.Get("login", func(mode AnswerType, w http.ResponseWriter, r *http.Request) *Error { if mode == JSON { return &Error{ code: 404, }; } LoadBasedOnAnswer(mode, w, "login.html", nil) return nil; }) handle.Startup() }