~repos /gromer

#golang#htmx#ssr

git clone https://pyrossh.dev/repos/gromer.git

gromer is a framework and cli to build multipage web apps in golang using htmx and alpinejs.


d16501a5 pyros2097

tag: v0.0.3

v0.0.3

5 years ago
change http to cli
Files changed (1) hide show
  1. {http → cli}/main.go +3 -2
{http → cli}/main.go RENAMED
@@ -255,8 +255,9 @@ func createPage(ui app.UI, wasmPath string) *bytes.Buffer {
255
255
  }
256
256
 
257
257
  func serve(wd string) {
258
+
258
- assetsFileServer := http.FileServer(pkger.Dir("./assets"))
259
+ assetsFileServer := http.FileServer(pkger.Dir(filepath.Join(wd, "assets")))
259
- buildFileServer := http.FileServer(pkger.Dir("./build"))
260
+ buildFileServer := http.FileServer(pkger.Dir(filepath.Join(wd, "build")))
260
261
 
261
262
  http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
262
263
  if render, ok := routesMap[r.URL.Path]; ok {