2024-10-28 15:32:50 +00:00
|
|
|
package snippets
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"htmgo-site/partials/snippets"
|
|
|
|
|
)
|
|
|
|
|
|
2024-10-28 15:56:03 +00:00
|
|
|
var FormWithLoadingStateSnippet = Snippet{
|
2024-10-28 15:32:50 +00:00
|
|
|
name: "Form",
|
|
|
|
|
description: "A simple form submission example with a loading state",
|
|
|
|
|
sidebarName: "Form with loading state",
|
|
|
|
|
path: "/snippets/form",
|
|
|
|
|
partial: snippets.FormExample,
|
|
|
|
|
}
|
|
|
|
|
|
2024-10-28 15:56:03 +00:00
|
|
|
var UserAuthSnippet = Snippet{
|
|
|
|
|
name: "User Authentication",
|
|
|
|
|
description: "An example showing basic user registration and login with htmgo",
|
|
|
|
|
sidebarName: "User Authentication",
|
|
|
|
|
path: "/snippets/user-auth",
|
|
|
|
|
externalRoute: "https://auth-example.htmgo.dev",
|
|
|
|
|
sourceCodePath: "https://github.com/maddalax/htmgo/tree/master/examples/simple-auth",
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var ChatSnippet = Snippet{
|
|
|
|
|
name: "Chat App",
|
|
|
|
|
description: "A simple chat application built with htmgo",
|
|
|
|
|
sidebarName: "Chat App",
|
|
|
|
|
path: "/snippets/chat",
|
|
|
|
|
externalRoute: "https://chat-example.htmgo.dev",
|
|
|
|
|
sourceCodePath: "https://github.com/maddalax/htmgo/tree/master/examples/chat",
|
|
|
|
|
}
|
|
|
|
|
|
2024-10-28 15:32:50 +00:00
|
|
|
var Snippets = []Snippet{
|
2024-10-28 15:56:03 +00:00
|
|
|
FormWithLoadingStateSnippet,
|
|
|
|
|
UserAuthSnippet,
|
|
|
|
|
ChatSnippet,
|
2024-10-28 15:32:50 +00:00
|
|
|
}
|