Documentation
¶
Overview ¶
Package template provides utility functions that help with the templating of created files.
Index ¶
- func AirTomlTemplate() []byte
- func GitIgnoreTemplate() []byte
- func MakeTemplate() []byte
- func NonDbMakeFileTemplate() []byte
- func ReadmeTemplate() []byte
- type ChiTemplates
- type EchoTemplates
- func (e EchoTemplates) HtmxTemplImports() []byte
- func (e EchoTemplates) HtmxTemplRoutes() []byte
- func (e EchoTemplates) Main() []byte
- func (e EchoTemplates) Routes() []byte
- func (e EchoTemplates) Server() []byte
- func (e EchoTemplates) TestHandler() []byte
- func (e EchoTemplates) WebsocketImports() []byte
- type FiberTemplates
- func (f FiberTemplates) HtmxTemplImports() []byte
- func (f FiberTemplates) HtmxTemplRoutes() []byte
- func (f FiberTemplates) Main() []byte
- func (f FiberTemplates) Routes() []byte
- func (f FiberTemplates) Server() []byte
- func (f FiberTemplates) TestHandler() []byte
- func (f FiberTemplates) WebsocketImports() []byte
- type GinTemplates
- type GorillaTemplates
- func (g GorillaTemplates) HtmxTemplImports() []byte
- func (g GorillaTemplates) HtmxTemplRoutes() []byte
- func (g GorillaTemplates) Main() []byte
- func (g GorillaTemplates) Routes() []byte
- func (g GorillaTemplates) Server() []byte
- func (g GorillaTemplates) TestHandler() []byte
- func (g GorillaTemplates) WebsocketImports() []byte
- type RouterTemplates
- func (r RouterTemplates) HtmxTemplImports() []byte
- func (r RouterTemplates) HtmxTemplRoutes() []byte
- func (r RouterTemplates) Main() []byte
- func (r RouterTemplates) Routes() []byte
- func (r RouterTemplates) Server() []byte
- func (r RouterTemplates) TestHandler() []byte
- func (r RouterTemplates) WebsocketImports() []byte
- type StandardLibTemplate
- func (s StandardLibTemplate) HtmxTemplImports() []byte
- func (s StandardLibTemplate) HtmxTemplRoutes() []byte
- func (s StandardLibTemplate) Main() []byte
- func (s StandardLibTemplate) Routes() []byte
- func (s StandardLibTemplate) Server() []byte
- func (s StandardLibTemplate) TestHandler() []byte
- func (s StandardLibTemplate) WebsocketImports() []byte
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AirTomlTemplate ¶
func AirTomlTemplate() []byte
func GitIgnoreTemplate ¶
func GitIgnoreTemplate() []byte
func MakeTemplate ¶
func MakeTemplate() []byte
MakeTemplate returns a byte slice that represents the default Makefile template.
func NonDbMakeFileTemplate ¶ added in v0.5.1
func NonDbMakeFileTemplate() []byte
func ReadmeTemplate ¶
func ReadmeTemplate() []byte
ReadmeTemplate returns a byte slice that represents the default README.md file template.
Types ¶
type ChiTemplates ¶
type ChiTemplates struct{}
ChiTemplates contains the methods used for building an app that uses github.com/go-chi/chi
func (ChiTemplates) HtmxTemplImports ¶ added in v0.5.0
func (c ChiTemplates) HtmxTemplImports() []byte
func (ChiTemplates) HtmxTemplRoutes ¶ added in v0.5.0
func (c ChiTemplates) HtmxTemplRoutes() []byte
func (ChiTemplates) Main ¶
func (c ChiTemplates) Main() []byte
func (ChiTemplates) Routes ¶
func (c ChiTemplates) Routes() []byte
func (ChiTemplates) Server ¶
func (c ChiTemplates) Server() []byte
func (ChiTemplates) TestHandler ¶ added in v0.3.1
func (c ChiTemplates) TestHandler() []byte
func (ChiTemplates) WebsocketImports ¶ added in v0.5.9
func (c ChiTemplates) WebsocketImports() []byte
type EchoTemplates ¶
type EchoTemplates struct{}
EchoTemplates contains the methods used for building an app that uses github.com/labstack/echo
func (EchoTemplates) HtmxTemplImports ¶ added in v0.5.0
func (e EchoTemplates) HtmxTemplImports() []byte
func (EchoTemplates) HtmxTemplRoutes ¶ added in v0.5.0
func (e EchoTemplates) HtmxTemplRoutes() []byte
func (EchoTemplates) Main ¶
func (e EchoTemplates) Main() []byte
func (EchoTemplates) Routes ¶
func (e EchoTemplates) Routes() []byte
func (EchoTemplates) Server ¶
func (e EchoTemplates) Server() []byte
func (EchoTemplates) TestHandler ¶ added in v0.3.1
func (e EchoTemplates) TestHandler() []byte
func (EchoTemplates) WebsocketImports ¶ added in v0.5.9
func (e EchoTemplates) WebsocketImports() []byte
type FiberTemplates ¶
type FiberTemplates struct{}
FiberTemplates contains the methods used for building an app that uses github.com/gofiber/fiber
func (FiberTemplates) HtmxTemplImports ¶ added in v0.5.0
func (f FiberTemplates) HtmxTemplImports() []byte
func (FiberTemplates) HtmxTemplRoutes ¶ added in v0.5.0
func (f FiberTemplates) HtmxTemplRoutes() []byte
func (FiberTemplates) Main ¶
func (f FiberTemplates) Main() []byte
func (FiberTemplates) Routes ¶
func (f FiberTemplates) Routes() []byte
func (FiberTemplates) Server ¶
func (f FiberTemplates) Server() []byte
func (FiberTemplates) TestHandler ¶ added in v0.3.1
func (f FiberTemplates) TestHandler() []byte
func (FiberTemplates) WebsocketImports ¶ added in v0.5.9
func (f FiberTemplates) WebsocketImports() []byte
type GinTemplates ¶
type GinTemplates struct{}
GinTemplates contains the methods used for building an app that uses github.com/gin-gonic/gin
func (GinTemplates) HtmxTemplImports ¶ added in v0.5.0
func (g GinTemplates) HtmxTemplImports() []byte
func (GinTemplates) HtmxTemplRoutes ¶ added in v0.5.0
func (g GinTemplates) HtmxTemplRoutes() []byte
func (GinTemplates) Main ¶
func (g GinTemplates) Main() []byte
func (GinTemplates) Routes ¶
func (g GinTemplates) Routes() []byte
func (GinTemplates) Server ¶
func (g GinTemplates) Server() []byte
func (GinTemplates) TestHandler ¶ added in v0.3.1
func (g GinTemplates) TestHandler() []byte
func (GinTemplates) WebsocketImports ¶ added in v0.5.9
func (g GinTemplates) WebsocketImports() []byte
type GorillaTemplates ¶
type GorillaTemplates struct{}
GorillaTemplates contains the methods used for building an app that uses github.com/gorilla/mux
func (GorillaTemplates) HtmxTemplImports ¶ added in v0.5.0
func (g GorillaTemplates) HtmxTemplImports() []byte
func (GorillaTemplates) HtmxTemplRoutes ¶ added in v0.5.0
func (g GorillaTemplates) HtmxTemplRoutes() []byte
func (GorillaTemplates) Main ¶
func (g GorillaTemplates) Main() []byte
func (GorillaTemplates) Routes ¶
func (g GorillaTemplates) Routes() []byte
func (GorillaTemplates) Server ¶
func (g GorillaTemplates) Server() []byte
func (GorillaTemplates) TestHandler ¶ added in v0.3.1
func (g GorillaTemplates) TestHandler() []byte
func (GorillaTemplates) WebsocketImports ¶ added in v0.5.9
func (g GorillaTemplates) WebsocketImports() []byte
type RouterTemplates ¶
type RouterTemplates struct{}
RouterTemplates contains the methods used for building an app that uses github.com/julienschmidt/httprouter
func (RouterTemplates) HtmxTemplImports ¶ added in v0.5.0
func (r RouterTemplates) HtmxTemplImports() []byte
func (RouterTemplates) HtmxTemplRoutes ¶ added in v0.5.0
func (r RouterTemplates) HtmxTemplRoutes() []byte
func (RouterTemplates) Main ¶
func (r RouterTemplates) Main() []byte
func (RouterTemplates) Routes ¶
func (r RouterTemplates) Routes() []byte
func (RouterTemplates) Server ¶
func (r RouterTemplates) Server() []byte
func (RouterTemplates) TestHandler ¶ added in v0.3.1
func (r RouterTemplates) TestHandler() []byte
func (RouterTemplates) WebsocketImports ¶ added in v0.5.9
func (r RouterTemplates) WebsocketImports() []byte
type StandardLibTemplate ¶
type StandardLibTemplate struct{}
StandardLibTemplate contains the methods used for building an app that uses net/http
func (StandardLibTemplate) HtmxTemplImports ¶ added in v0.5.0
func (s StandardLibTemplate) HtmxTemplImports() []byte
func (StandardLibTemplate) HtmxTemplRoutes ¶ added in v0.5.0
func (s StandardLibTemplate) HtmxTemplRoutes() []byte
func (StandardLibTemplate) Main ¶
func (s StandardLibTemplate) Main() []byte
func (StandardLibTemplate) Routes ¶
func (s StandardLibTemplate) Routes() []byte
func (StandardLibTemplate) Server ¶
func (s StandardLibTemplate) Server() []byte
func (StandardLibTemplate) TestHandler ¶ added in v0.3.1
func (s StandardLibTemplate) TestHandler() []byte
func (StandardLibTemplate) WebsocketImports ¶ added in v0.5.9
func (s StandardLibTemplate) WebsocketImports() []byte