burrow

package module
v0.0.0-...-9c7a04a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 8, 2026 License: EUPL-1.2 Imports: 39 Imported by: 0

README

Burrow

A Go web framework library built on Chi, Bun/SQLite, and Go's standard html/template. Designed around composable apps with a Django-inspired architecture.

Features

  • App-based architecture — build your application from composable, self-contained apps
  • Pure Go SQLite — no CGO required (CGO_ENABLED=0), cross-compiles anywhere
  • Per-app migrations — each app manages its own SQL migrations
  • Standard templates — Go's html/template with a global template set, per-app FuncMaps, and automatic layout wrapping
  • CSS-agnostic — bring your own CSS framework (Bootstrap, Tailwind, etc.)
  • Layout system — app layout via server, admin layout via admin package
  • CLI configuration — flags, environment variables, and TOML config via urfave/cli
  • CSRF protection — automatic token generation and validation
  • Flash messages — session-based flash message system
  • Bootstrap integration — Bootstrap 5 CSS/JS, inline SVG icons, htmx, and dark mode theme switcher
  • Contrib apps — auth (WebAuthn/passkeys), sessions, i18n, admin, CSRF, flash messages, jobs, uploads, rate limiting, healthcheck, static files

Quick Start

package main

import (
    "context"
    "log"
    "os"

    "codeberg.org/oliverandrich/burrow"
    "codeberg.org/oliverandrich/burrow/contrib/healthcheck"
    "codeberg.org/oliverandrich/burrow/contrib/session"
    "github.com/urfave/cli/v3"
)

func main() {
    srv := burrow.NewServer(
        session.New(),
        healthcheck.New(),
    )

    cmd := &cli.Command{
        Name:   "myapp",
        Flags:  srv.Flags(nil),
        Action: srv.Run,
    }

    if err := cmd.Run(context.Background(), os.Args); err != nil {
        log.Fatal(err)
    }
}

See example/hello/ for a minimal hello world app, or example/notes/ for a complete example with auth, admin, i18n, and more.

Architecture

contrib/        Reusable apps
  admin/        Admin panel coordinator + ModelAdmin
  auth/         WebAuthn passkeys, recovery codes, email verification
  authmail/     Pluggable email renderer + SMTP implementation
  bootstrap/    Bootstrap 5 CSS/JS/htmx assets, theme switcher, layout
  bsicons/      Bootstrap Icons as inline SVG template functions
  csrf/         CSRF protection
  healthcheck/  /healthz endpoint
  htmx/         htmx static asset + request/response helpers
  i18n/         Locale detection and translations
  jobs/         SQLite-backed background job queue
  messages/     Flash messages
  ratelimit/    Per-client rate limiting
  session/      Cookie-based sessions
  staticfiles/  Static file serving with content-hashed URLs
  uploads/      File upload storage and serving
example/        Example applications (hello world, notes app)
The App Interface

Every app implements burrow.App:

type App interface {
    Name() string
    Register(cfg *AppConfig) error
}

Apps can optionally implement additional interfaces:

Interface Purpose
Migratable Provide embedded SQL migrations
HasRoutes Register HTTP routes
HasMiddleware Contribute middleware
HasNavItems Contribute navigation items
HasTemplates Contribute .html template files
HasFuncMap Contribute static template functions
HasRequestFuncMap Contribute request-scoped template functions
Configurable Define CLI flags and read configuration
HasCLICommands Contribute CLI subcommands
Seedable Seed the database with initial data
HasAdmin Contribute admin panel routes and nav items
HasStaticFiles Contribute embedded static file assets
HasTranslations Contribute translation files
HasDependencies Declare required apps
HasShutdown Clean up on graceful shutdown
Layouts

The app layout wraps user-facing pages:

srv.SetLayout(appLayout)

The admin layout is owned by the admin package:

admin.New(admin.WithLayout(layout), admin.WithDashboardRenderer(dashboardRenderer))

A LayoutFunc receives the response writer, request, status code, rendered content, and template data:

type LayoutFunc func(w http.ResponseWriter, r *http.Request, code int, content template.HTML, data map[string]any) error

Layouts access framework values from the request context:

burrow.NavItems(ctx)    // Navigation items from all apps
burrow.Layout(ctx)      // App layout function
csrf.Token(ctx)         // CSRF token for forms
Configuration

Configuration is resolved in order: CLI flags > environment variables > TOML file.

Core flags include --host, --port, --database-dsn, --log-level, --log-format, --tls-mode, and more. Apps can contribute their own flags via the Configurable interface.

Migrations

Apps embed their SQL migrations and implement Migratable:

//go:embed migrations
var migrationFS embed.FS

func (a *App) MigrationFS() fs.FS {
    sub, _ := fs.Sub(migrationFS, "migrations")
    return sub
}

Migrations are tracked per-app in the _migrations table and run automatically on startup.

Development

just setup          # Check that all required dev tools are installed
just test           # Run all tests
just lint           # Run golangci-lint
just fmt            # Format code
just coverage       # Generate coverage report
just tidy           # Tidy module dependencies
just example-hello  # Run the hello world example
just example-notes  # Run the notes example application

Requires Go 1.25+. Run just setup to verify your dev environment.

Documentation

Full documentation is available in the docs/ directory.

License

See LICENSE. Third-party licenses are listed in THIRD_PARTY_LICENSES.md.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyCursor

func ApplyCursor(q *bun.SelectQuery, pr PageRequest, orderColumn string) *bun.SelectQuery

ApplyCursor applies cursor-based pagination to a Bun SelectQuery. It orders by orderColumn DESC and fetches limit+1 rows to detect whether more items exist. Use TrimCursorResults to trim the extra item.

func ApplyOffset

func ApplyOffset(q *bun.SelectQuery, pr PageRequest) *bun.SelectQuery

ApplyOffset applies offset-based pagination to a Bun SelectQuery.

func Bind

func Bind(r *http.Request, v any) error

Bind parses the request body into the given struct and validates it. It supports JSON, multipart/form-data, and form-encoded bodies. Form decoding supports all types (string, int, bool, float, etc.) via struct tags. Validation uses "validate" struct tags; structs without them pass through unchanged.

func ContextValue

func ContextValue[T any](ctx context.Context, key any) (T, bool)

ContextValue retrieves a typed value from the context.

func CoreFlags

func CoreFlags(configSource func(key string) cli.ValueSource) []cli.Flag

CoreFlags returns the CLI flags for core framework configuration. If configSource is provided, it is used as an additional value source (e.g. a TOML file sourcer) for each flag.

func FlagSources

func FlagSources(configSource func(key string) cli.ValueSource, envVar, tomlKey string) cli.ValueSourceChain

FlagSources builds a cli.ValueSourceChain from an environment variable and an optional TOML key. If configSource is nil, only the env var is used. This is the standard way for contrib apps to wire up flag sources:

src := burrow.FlagSources(configSource, "MY_ENV_VAR", "app.toml_key")

func HTML

func HTML(w http.ResponseWriter, code int, s string) error

HTML writes an HTML response with the given status code.

func Handle

func Handle(fn HandlerFunc) http.HandlerFunc

Handle converts a HandlerFunc into a standard http.HandlerFunc with centralized error handling.

func IsLocalhost

func IsLocalhost(host string) bool

IsLocalhost checks if the host is a localhost address.

func JSON

func JSON(w http.ResponseWriter, code int, v any) error

JSON writes a JSON response with the given status code.

func Render

func Render(w http.ResponseWriter, r *http.Request, statusCode int, content template.HTML) error

Render writes pre-rendered HTML content to the response. Used for raw HTML output, HTMX fragments, or special cases where content is already rendered.

func RenderTemplate

func RenderTemplate(w http.ResponseWriter, r *http.Request, statusCode int, name string, data map[string]any) error

RenderTemplate executes a named template and writes the result. It applies automatic layout/HTMX logic:

  • HTMX request (HX-Request header) → fragment only, no layout
  • Normal request + LayoutFunc in context → fragment wrapped in layout
  • Normal request + no layout → fragment only

func RunAppMigrations

func RunAppMigrations(ctx context.Context, db *bun.DB, appName string, migrations fs.FS) error

RunAppMigrations runs all unapplied .up.sql migrations from the given FS for the named app. Migrations are tracked in the _migrations table, namespaced by app name.

func Text

func Text(w http.ResponseWriter, code int, s string) error

Text writes a plain text response with the given status code.

func TrimCursorResults

func TrimCursorResults[T any](items []T, limit int) ([]T, bool)

TrimCursorResults trims a result slice that was fetched with limit+1. It returns the trimmed slice and whether more items exist beyond the limit.

func Validate

func Validate(v any) error

Validate validates a struct using "validate" struct tags. Returns nil if v is not a struct, has no validate tags, or passes all checks.

func WithContextValue

func WithContextValue(ctx context.Context, key, val any) context.Context

WithContextValue returns a new context with the given key-value pair.

func WithLayout

func WithLayout(ctx context.Context, fn LayoutFunc) context.Context

WithLayout stores the app layout function in the context.

func WithNavItems

func WithNavItems(ctx context.Context, items []NavItem) context.Context

WithNavItems stores navigation items in the context.

func WithTemplateExecutor

func WithTemplateExecutor(ctx context.Context, exec TemplateExecutor) context.Context

WithTemplateExecutor stores the template executor in the context.

Types

type App

type App interface {
	Name() string
	Register(cfg *AppConfig) error
}

App is the required interface that all apps must implement. An app has a unique name and a Register method that receives the shared configuration needed to wire into the framework.

type AppConfig

type AppConfig struct {
	DB       *bun.DB
	Registry *Registry
	Config   *Config
}

AppConfig is passed to each app's Register method, providing access to shared framework resources.

type Config

type Config struct {
	TLS      TLSConfig
	Database DatabaseConfig
	Server   ServerConfig
}

Config holds core framework configuration.

func NewConfig

func NewConfig(cmd *cli.Command) *Config

NewConfig creates a Config from a parsed CLI command.

func (*Config) ResolveBaseURL

func (c *Config) ResolveBaseURL() string

ResolveBaseURL computes the base URL from server and TLS config if BaseURL is not explicitly set.

func (*Config) ValidateTLS

func (c *Config) ValidateTLS(cmd *cli.Command) error

ValidateTLS checks that the TLS configuration is consistent. Call this early (before opening the database) to fail fast on misconfigurations.

type Configurable

type Configurable interface {
	Flags(configSource func(key string) cli.ValueSource) []cli.Flag
	Configure(cmd *cli.Command) error
}

Configurable is implemented by apps that define CLI flags and need to read their configuration from the CLI command. The configSource parameter enables TOML file sourcing; it may be nil when only ENV/CLI sources are used.

type DatabaseConfig

type DatabaseConfig struct {
	DSN string
}

DatabaseConfig holds database settings.

type FieldError

type FieldError struct {
	Field   string `json:"field"`
	Tag     string `json:"tag"`
	Param   string `json:"param,omitempty"`
	Value   any    `json:"value"`
	Message string `json:"message"`
}

FieldError represents a validation failure on a single field.

type HTTPError

type HTTPError struct {
	Message string
	Code    int
}

HTTPError represents an HTTP error with a status code and message.

func NewHTTPError

func NewHTTPError(code int, message string) *HTTPError

NewHTTPError creates a new HTTPError.

func (*HTTPError) Error

func (e *HTTPError) Error() string

type HandlerFunc

type HandlerFunc func(w http.ResponseWriter, r *http.Request) error

HandlerFunc is an HTTP handler that returns an error. Use Handle() to convert it to a standard http.HandlerFunc.

type HasAdmin

type HasAdmin interface {
	AdminRoutes(r chi.Router)
	AdminNavItems() []NavItem
}

HasAdmin is implemented by apps that contribute admin panel routes and navigation items. AdminRoutes receives a chi router already prefixed with /admin and protected by auth middleware.

type HasCLICommands

type HasCLICommands interface {
	CLICommands() []*cli.Command
}

HasCLICommands is implemented by apps that contribute subcommands.

type HasDependencies

type HasDependencies interface {
	Dependencies() []string
}

HasDependencies is implemented by apps that require other apps to be registered first. Dependencies() returns the names of required apps; registration panics if any are missing.

type HasFuncMap

type HasFuncMap interface {
	FuncMap() template.FuncMap
}

HasFuncMap is implemented by apps that provide static template functions. These are added once at boot time and available in all templates.

type HasMiddleware

type HasMiddleware interface {
	Middleware() []func(http.Handler) http.Handler
}

HasMiddleware is implemented by apps that contribute HTTP middleware.

type HasNavItems

type HasNavItems interface {
	NavItems() []NavItem
}

HasNavItems is implemented by apps that contribute navigation items.

type HasRequestFuncMap

type HasRequestFuncMap interface {
	RequestFuncMap(r *http.Request) template.FuncMap
}

HasRequestFuncMap is implemented by apps that provide request-scoped template functions (e.g., CSRF tokens, current user, translations). These are added per request via middleware using template.Clone().

type HasRoutes

type HasRoutes interface {
	Routes(r chi.Router)
}

HasRoutes is implemented by apps that register HTTP routes.

type HasShutdown

type HasShutdown interface {
	Shutdown(ctx context.Context) error
}

HasShutdown is implemented by apps that need to perform cleanup during graceful shutdown (e.g., stopping background goroutines, flushing buffers). Called in reverse registration order before the HTTP server stops.

type HasStaticFiles

type HasStaticFiles interface {
	StaticFS() (prefix string, fsys fs.FS)
}

HasStaticFiles is implemented by apps that contribute static file assets. The returned prefix namespaces the files under the static URL path (e.g., prefix "admin" serves files at /static/admin/...).

type HasTemplates

type HasTemplates interface {
	TemplateFS() fs.FS
}

HasTemplates is implemented by apps that provide HTML template files. The returned fs.FS should contain .html files with {{ define "appname/..." }} blocks. Templates are parsed once at boot time into the global template set.

type HasTranslations

type HasTranslations interface {
	TranslationFS() fs.FS
}

HasTranslations is implemented by apps that contribute translation files. The returned fs.FS must contain a "translations/" directory with TOML files (e.g., "translations/active.en.toml").

type LayoutFunc

type LayoutFunc func(w http.ResponseWriter, r *http.Request, code int, content template.HTML, data map[string]any) error

LayoutFunc wraps page content in a layout template. The layout reads framework values (nav items, user, locale, CSRF) from the request context via helper functions.

func Layout

func Layout(ctx context.Context) LayoutFunc

Layout retrieves the app layout function from the context.

type Migratable

type Migratable interface {
	MigrationFS() fs.FS
}

Migratable is implemented by apps that provide database migrations.

type NavItem struct {
	Label     string
	LabelKey  string // i18n message ID; translated at render time, falls back to Label
	URL       string
	Icon      template.HTML
	Position  int
	AuthOnly  bool
	AdminOnly bool
}

NavItem represents a navigation entry contributed by an app.

func NavItems(ctx context.Context) []NavItem

NavItems retrieves the navigation items from the context.

type PageRequest

type PageRequest struct {
	Limit  int    // items per page (default 20, max 100)
	Cursor string // opaque cursor for cursor-based pagination (empty = first page)
	Page   int    // 1-based page number for offset-based pagination (0 = not used)
}

PageRequest holds pagination parameters parsed from a query string.

func ParsePageRequest

func ParsePageRequest(r *http.Request) PageRequest

ParsePageRequest extracts pagination parameters from the request query string. If both cursor and page are present, cursor takes precedence.

func (PageRequest) Offset

func (pr PageRequest) Offset() int

Offset returns the SQL OFFSET for the current page. Page 0 and 1 both return offset 0.

type PageResponse

type PageResponse[T any] struct {
	Items      []T        `json:"items"`
	Pagination PageResult `json:"pagination"`
}

PageResponse wraps items with pagination metadata for JSON APIs.

type PageResult

type PageResult struct {
	NextCursor string `json:"next_cursor,omitempty"` // cursor for next page (empty = no more)
	PrevCursor string `json:"prev_cursor,omitempty"` // cursor for previous page (empty = first page)
	HasMore    bool   `json:"has_more"`              // convenience: NextCursor != ""
	// Offset-based fields (only populated when using offset pagination):
	Page       int `json:"page,omitempty"`        // current page number (1-based)
	TotalPages int `json:"total_pages,omitempty"` // total number of pages
	TotalCount int `json:"total_count,omitempty"` // total number of items
}

PageResult holds pagination metadata returned alongside items.

func CursorResult

func CursorResult(lastCursor string, hasMore bool) PageResult

CursorResult builds a PageResult for cursor-based pagination. lastCursor is the cursor value of the last item in the current page. hasMore indicates whether there are more items after this page.

func OffsetResult

func OffsetResult(pr PageRequest, totalCount int) PageResult

OffsetResult builds a PageResult for offset-based pagination.

type Registry

type Registry struct {
	// contains filtered or unexported fields
}

Registry holds registered apps in insertion order.

func NewRegistry

func NewRegistry() *Registry

NewRegistry creates an empty Registry.

func (*Registry) Add

func (r *Registry) Add(app App)

Add registers an app. It panics if an app with the same name has already been registered or if a declared dependency is missing (programming errors caught at startup).

func (*Registry) AllAdminNavItems

func (r *Registry) AllAdminNavItems() []NavItem

AllAdminNavItems collects AdminNavItems from all HasAdmin apps and returns them sorted by Position (stable sort preserves insertion order for equal positions).

func (*Registry) AllCLICommands

func (r *Registry) AllCLICommands() []*cli.Command

AllCLICommands collects CLI subcommands from all HasCLICommands apps.

func (*Registry) AllFlags

func (r *Registry) AllFlags(configSource func(key string) cli.ValueSource) []cli.Flag

AllFlags collects CLI flags from all Configurable apps. Pass configSource to enable TOML file sourcing (or nil for ENV-only).

func (*Registry) AllNavItems

func (r *Registry) AllNavItems() []NavItem

AllNavItems collects NavItems from all HasNavItems apps and returns them sorted by Position (stable sort preserves insertion order for equal positions).

func (*Registry) Apps

func (r *Registry) Apps() []App

Apps returns all registered apps in the order they were added.

func (*Registry) Configure

func (r *Registry) Configure(cmd *cli.Command) error

Configure calls Configure on each Configurable app. It stops and returns on the first error.

func (*Registry) Get

func (r *Registry) Get(name string) (App, bool)

Get returns the app with the given name, or false if not found.

func (*Registry) RegisterAll

func (r *Registry) RegisterAll(db *bun.DB) error

RegisterAll calls Register on each app in order, passing a partial AppConfig (DB + Registry only, no Config/migrations/seeds). This is a test convenience; the real boot sequence lives in Server.bootstrap().

func (*Registry) RegisterMiddleware

func (r *Registry) RegisterMiddleware(router chi.Router)

RegisterMiddleware applies middleware from all HasMiddleware apps to the chi router, in app registration order.

func (*Registry) RegisterRoutes

func (r *Registry) RegisterRoutes(router chi.Router)

RegisterRoutes calls Routes on each HasRoutes app, allowing apps to register their HTTP handlers.

func (*Registry) RunMigrations

func (r *Registry) RunMigrations(ctx context.Context, db *bun.DB) error

RunMigrations runs migrations for all Migratable apps in registration order.

func (*Registry) Seed

func (r *Registry) Seed(ctx context.Context) error

Seed calls Seed on each Seedable app in order. It stops and returns on the first error.

func (*Registry) Shutdown

func (r *Registry) Shutdown(ctx context.Context) error

Shutdown calls Shutdown on each HasShutdown app in reverse registration order. Errors are collected but do not prevent other apps from shutting down.

type Seedable

type Seedable interface {
	Seed(ctx context.Context) error
}

Seedable is implemented by apps that can seed the database with initial data.

type Server

type Server struct {
	// contains filtered or unexported fields
}

Server is the main framework entry point. It holds the Registry of apps and orchestrates the boot sequence.

func NewServer

func NewServer(apps ...App) *Server

NewServer creates a Server and registers the given apps. Apps are automatically sorted so that dependencies are registered before the apps that need them. The relative order of independent apps is preserved. NewServer panics if a dependency is missing from the input or if there is a dependency cycle.

func (*Server) Flags

func (s *Server) Flags(configSource func(key string) cli.ValueSource) []cli.Flag

Flags returns all CLI flags: core framework flags merged with flags from all Configurable apps. Pass a configSource to enable TOML file sourcing (or nil for ENV-only).

func (*Server) Registry

func (s *Server) Registry() *Registry

Registry returns the server's app registry.

func (*Server) Run

func (s *Server) Run(ctx context.Context, cmd *cli.Command) error

Run is a cli.ActionFunc that boots and starts the server. It opens the database, runs migrations, bootstraps apps, configures apps, and starts the HTTP server with graceful shutdown.

func (*Server) SetLayout

func (s *Server) SetLayout(fn LayoutFunc)

SetLayout configures the app layout function.

type ServerConfig

type ServerConfig struct {
	Host            string
	BaseURL         string
	PIDFile         string
	Port            int
	MaxBodySize     int // in MB
	ShutdownTimeout int // in seconds
}

ServerConfig holds HTTP server settings.

type TLSConfig

type TLSConfig struct {
	Mode     string // auto, acme, selfsigned, manual, off
	CertDir  string
	Email    string
	CertFile string
	KeyFile  string
}

TLSConfig holds TLS settings.

type TemplateExecutor

type TemplateExecutor func(r *http.Request, name string, data map[string]any) (template.HTML, error)

TemplateExecutor executes a named template with the given data and returns the rendered HTML. It is stored in the request context by the template middleware and used by RenderTemplate.

func TemplateExecutorFromContext

func TemplateExecutorFromContext(ctx context.Context) TemplateExecutor

TemplateExecutorFromContext retrieves the template executor from the context.

type ValidationError

type ValidationError struct {
	Errors []FieldError
}

ValidationError is returned by Bind()/Validate() when validation fails.

func (*ValidationError) Error

func (e *ValidationError) Error() string

func (*ValidationError) HasField

func (e *ValidationError) HasField(name string) bool

HasField reports whether the validation error contains a failure for the named field.

Directories

Path Synopsis
contrib
admin/modeladmin
Package modeladmin provides a generic, Django-style ModelAdmin for auto-generating CRUD admin views from Bun models.
Package modeladmin provides a generic, Django-style ModelAdmin for auto-generating CRUD admin views from Bun models.
auth
Package auth provides authentication as a burrow contrib app.
Package auth provides authentication as a burrow contrib app.
authmail
Package authmail defines the Renderer interface for auth email templates.
Package authmail defines the Renderer interface for auth email templates.
authmail/smtpmail
Package smtpmail provides an SMTP-based implementation of auth.EmailService with pluggable email templates via authmail.Renderer.
Package smtpmail provides an SMTP-based implementation of auth.EmailService with pluggable email templates via authmail.Renderer.
bootstrap
Package bootstrap provides a design system contrib app using Bootstrap 5, Bootstrap Icons, and htmx.
Package bootstrap provides a design system contrib app using Bootstrap 5, Bootstrap Icons, and htmx.
bsicons
Package bsicons provides all Bootstrap Icons as inline SVG template.HTML values.
Package bsicons provides all Bootstrap Icons as inline SVG template.HTML values.
bsicons/internal/generate command
Command generate reads Bootstrap Icons SVG files and outputs a Go source file containing the icon data and named accessor functions.
Command generate reads Bootstrap Icons SVG files and outputs a Go source file containing the icon data and named accessor functions.
csrf
Package csrf provides CSRF protection as a burrow contrib app.
Package csrf provides CSRF protection as a burrow contrib app.
healthcheck
Package healthcheck provides a minimal health check app for burrow.
Package healthcheck provides a minimal health check app for burrow.
htmx
Package htmx provides request detection and response helpers for htmx, inspired by django-htmx.
Package htmx provides request detection and response helpers for htmx, inspired by django-htmx.
i18n
Package i18n provides internationalization as a burrow contrib app.
Package i18n provides internationalization as a burrow contrib app.
jobs
Package jobs provides an in-process, SQLite-backed background job queue as a burrow contrib app.
Package jobs provides an in-process, SQLite-backed background job queue as a burrow contrib app.
messages
Package messages provides flash message support as a burrow contrib app.
Package messages provides flash message support as a burrow contrib app.
ratelimit
Package ratelimit provides per-client rate limiting as a burrow contrib app.
Package ratelimit provides per-client rate limiting as a burrow contrib app.
session
Package session provides cookie-based session management as a burrow contrib app.
Package session provides cookie-based session management as a burrow contrib app.
staticfiles
Package staticfiles provides static file serving as a burrow contrib app.
Package staticfiles provides static file serving as a burrow contrib app.
uploads
Package uploads provides file upload storage as a burrow contrib app.
Package uploads provides file upload storage as a burrow contrib app.
example
hello command
Command hello is a minimal burrow application that serves a single "Hello, World!" page with Bootstrap styling and i18n support.
Command hello is a minimal burrow application that serves a single "Hello, World!" page with Bootstrap styling and i18n support.
notes/cmd/server command
Command server demonstrates how to build an application using the burrow framework with contrib apps.
Command server demonstrates how to build an application using the burrow framework with contrib apps.
notes/internal/notes
Package notes is an example custom app demonstrating the burrow framework.
Package notes is an example custom app demonstrating the burrow framework.
notes/internal/pages
Package pages provides the example app's static pages (homepage), layout rendering, and request-path middleware for active nav link highlighting.
Package pages provides the example app's static pages (homepage), layout rendering, and request-path middleware for active nav link highlighting.
internal
cryptokey
Package cryptokey provides shared utilities for resolving and decoding hex-encoded 32-byte cryptographic keys used by contrib apps (csrf, session).
Package cryptokey provides shared utilities for resolving and decoding hex-encoded 32-byte cryptographic keys used by contrib apps (csrf, session).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL