Saturday, March 11, 2023
HomeGolangTask run trouble - Obtaining Aid

Task run trouble – Obtaining Aid


mistake
bundle command-line-arguments
imports GitHub – gorilla/mux: An effective HTTP router and also link matcher for structure Go internet servers with
imports github.com/gorilla/mux: import cycle not enabled

routes.go

 bundle major.

import (.
" log".

" github.com/gorilla/mux".
).

func AddApproutes( path * mux.Router) {

log.Println(" Loadeding Routes ...").

route.HandleFunc(" https://forum.golangbridge.org/", RenderHome).

route.HandleFunc("/ sendEmail", SendEmailHandler). Approaches(" BLOG POST").

log.Println(" Courses are Packed.").
}

server.go

 bundle major.

import (.
" log".
" net/http".

" github.com/gorilla/mux".
).

func major() {

log.Println(" Web server will certainly begin at http://localhost:8000/").

path:= mux.NewRouter().

AddApproutes( path).

log.Fatal( http.ListenAndServe(":8000", path)).
}


What is your component name?

component GitHub – gorilla/mux: An effective HTTP router and also link matcher for structure Go internet servers with

go 1.19

You need to offer your component a name that you manage, and also not duplicate the name that mux is currently utilizing

RELATED ARTICLES

Most Popular

Recent Comments