Add static page routing, place API under /api/
This commit is contained in:
parent
e89af34c5c
commit
d635420a9f
3 changed files with 29 additions and 9 deletions
9
admin/static.go
Normal file
9
admin/static.go
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func StaticRouting(w http.ResponseWriter, r *http.Request) {
|
||||
http.ServeFile(w, r, "./static/index.html")
|
||||
}
|
||||
Reference in a new issue