bunapp

package module
v0.0.0-...-099376c Latest Latest
Warning

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

Go to latest
Published: Jan 2, 2023 License: MIT Imports: 11 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

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

func New

func New(ctx context.Context, config AppConfig) *App

func (*App) DB

func (app *App) DB() *DB

func (*App) Router

func (app *App) Router() *Router

func (*App) Run

func (app *App) Run(addr string) error

type AppConfig

type AppConfig struct {
	DB          *bun.DB
	Middlewares []bunrouter.MiddlewareFunc
}

type DB

type DB struct {
	*bun.DB
}

func (*DB) AutoMigrate

func (db *DB) AutoMigrate(ctx context.Context, migrations *migrate.Migrations) error

type Router

type Router struct {
	*bunrouter.Router
}

Directories

Path Synopsis
example module
x

Jump to

Keyboard shortcuts

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