Static demo of the Cloudzilla UI. Sample data, nothing is saved. All screens cloudzilla.dev

mkappworks cloudzilla internal router router.go

Blame for internal/router/router.go

internal/router/router.go

27 lines · 2 contributors
Per-line blame annotations for internal/router/router.go
Last commit Line Code
96a6f51 malith
1 package router
2
3 import (
4 "net/http"
5
6 "github.com/go-chi/chi/v5"
7 "github.com/mkappworks-dev/cloudzilla-app/internal/handler"
8 )
2a5f3ec daisy
9
10 // New returns a chi router with all Cloudzilla routes registered.
11 func New(h *handler.Handlers) http.Handler {
12 r := chi.NewRouter()
c0ca250 malith
13
14 r.Get("/", h.Home)
15 r.Get("/explore", h.Explore)
16
420b44b malith
17 r.Route("/{owner}/{repo}", func(r chi.Router) {
c0ca250 malith
18 r.Get("/", h.PageRepo)
19 r.Get("/tree/*", h.PageTree)
1439e1e daisy
20 r.Get("/blob/*", h.PageBlob)
21 r.Get("/blame/*", h.PageBlame)
22 r.Get("/commits/*", h.PageCommits)
96a6f51 malith
23 r.Get("/pulse", h.PagePulse)
24 })
25
26 return r
27 }

A vertical bar marks consecutive lines from the same commit — only the first row in each run shows the commit metadata.