-
Notifications
You must be signed in to change notification settings - Fork 0
/
web-app.go
152 lines (109 loc) · 3.98 KB
/
web-app.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
package templates
import (
_ "embed"
)
//go:embed files/assets/users.tmpl
var webAppUsersHtmlTemplate []byte
func WebAppUsersHtmlTemplateTemplate() ([]byte, string) {
return webAppUsersHtmlTemplate, "assets/users.html"
}
//go:embed files/assets/user.tmpl
var webAppUserHtmlTemplate []byte
func WebAppUserHtmlTemplateTemplate() ([]byte, string) {
return webAppUserHtmlTemplate, "assets/user.html"
}
//go:embed files/assets/styles.tmpl
var webAppStyles []byte
func WebAppStylesTemplate() ([]byte, string) {
return webAppStyles, "assets/styles.css"
}
//go:embed files/env.tmpl
var webAppEnv []byte
func WebAppEnvTemplate() ([]byte, string) {
return webAppEnv, ".env"
}
//go:embed files/readme/readme.tmpl
var webAppReadme []byte
func WebAppReadmeTemplate() ([]byte, string) {
return webAppReadme, "README.md"
}
//go:embed files/readme/readme-with-db.tmpl
var readme []byte
func WebAppReadmeWithDbTemplate() ([]byte, string) {
return readme, "README.md"
}
//go:embed files/cmd/server/server.tmpl
var webAppServer []byte
func WebAppServerTemplate() ([]byte, string) {
return webAppServer, "cmd/server/server.go"
}
//go:embed files/internal/adapters/handlers/http/routes.tmpl
var webAppHttpRoutes []byte
func WebAppHttpRoutesTemplate() ([]byte, string) {
return webAppHttpRoutes, "internal/adapters/handlers/http/routes.go"
}
//go:embed files/internal/adapters/handlers/http/users.tmpl
var webAppHttpUsers []byte
func WebAppHttpUsersTemplate() ([]byte, string) {
return webAppHttpUsers, "internal/adapters/handlers/http/users.go"
}
//go:embed files/internal/adapters/handlers/chi/routes.tmpl
var webAppChiRoutes []byte
func WebAppChiRoutesTemplate() ([]byte, string) {
return webAppChiRoutes, "internal/adapters/handlers/chi/routes.go"
}
//go:embed files/internal/adapters/handlers/chi/users.tmpl
var webAppHttpChiUsers []byte
func WebAppChiUsersTemplate() ([]byte, string) {
return webAppHttpChiUsers, "internal/adapters/handlers/chi/users.go"
}
//go:embed files/internal/adapters/handlers/echo/routes.tmpl
var webAppEchoRoutes []byte
func WebAppEchoRoutesTemplate() ([]byte, string) {
return webAppEchoRoutes, "internal/adapters/handlers/echo/routes.go"
}
//go:embed files/internal/adapters/handlers/echo/users.tmpl
var webAppHttpEchoUsers []byte
func WebAppEchoUsersTemplate() ([]byte, string) {
return webAppHttpEchoUsers, "internal/adapters/handlers/echo/users.go"
}
//go:embed files/internal/adapters/handlers/gin/routes.tmpl
var webAppGinRoutes []byte
func WebAppGinRoutesTemplate() ([]byte, string) {
return webAppGinRoutes, "internal/adapters/handlers/gin/routes.go"
}
//go:embed files/internal/adapters/handlers/gin/users.tmpl
var webAppHttpGinUsers []byte
func WebAppGinUsersTemplate() ([]byte, string) {
return webAppHttpGinUsers, "internal/adapters/handlers/gin/users.go"
}
//go:embed files/internal/adapters/handlers/gorilla/routes.tmpl
var webAppGorillaRoutes []byte
func WebAppGorillaRoutesTemplate() ([]byte, string) {
return webAppGorillaRoutes, "internal/adapters/handlers/gorilla/routes.go"
}
//go:embed files/internal/adapters/handlers/gorilla/users.tmpl
var webAppHttpGorillaUsers []byte
func WebAppGorillaUsersTemplate() ([]byte, string) {
return webAppHttpGorillaUsers, "internal/adapters/handlers/gorilla/users.go"
}
//go:embed files/internal/adapters/handlers/httprouter/routes.tmpl
var webAppHttprouterRoutes []byte
func WebAppHttprouterRoutesTemplate() ([]byte, string) {
return webAppHttprouterRoutes, "internal/adapters/handlers/httprouter/routes.go"
}
//go:embed files/internal/adapters/handlers/httprouter/users.tmpl
var webAppHttpHttprouterUsers []byte
func WebAppHttprouterUsersTemplate() ([]byte, string) {
return webAppHttpHttprouterUsers, "internal/adapters/handlers/httprouter/users.go"
}
//go:embed files/cmd/main.tmpl
var webAppMain []byte
func WebAppMainTemplate() ([]byte, string) {
return webAppMain, "cmd/main.go"
}
//go:embed files/cmd/main-with-db.tmpl
var webAppMainWithDb []byte
func WebAppMainWithDbTemplate() ([]byte, string) {
return webAppMainWithDb, "cmd/main.go"
}