package module
Version: v1.0.11 Latest Latest

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

Go to latest
Published: May 19, 2022 License: Apache-2.0 Imports: 19 Imported by: 0



                                   | |
 _____  ____    ___   _ _ _  _____ | |__
(____ ||  _ \  / _ \ | | | || ___ ||  _ \ 
/ ___ || | | || |_| || | | || ____|| |_) )
\_____||_| |_| \___/  \___/ |_____)|____/ 


The lightweight and powerful web framework using the new way for Go. Another go the way.

{{ Version @VER }}

{{ Powered by go-the-way }}

{{ }}

CircleCI GitHub go.mod Go version codecov Go Report Card GoDoc Release Mentioned in Awesome Go



  • Pure native, no third dependencies
  • Basic & Variables & Group router
  • REST-ful controllers
  • Binding & validation
  • Middleware supports
  • Session supports
  • Rich Response supports


require latest


package main

import (

func main() {
	go func() {
		time.AfterFunc(time.Second, func() {
			response, _ := http.Get("http://localhost:9494")
			resp, _ := ioutil.ReadAll(response.Body)
	anoweb.Default.Get("/", func(ctx *context.Context) {
		ctx.Text("Hello world")



Package anoweb doc


The lightweight and powerful web framework using the new way for Go. Another go the way.

{{ Version @VER }}

{{ Powered by go-the-way }}

{{ }}


package main

import (



func main() {

anoweb.Default.Get("/", func(ctx *context.Context) {
	ctx.Text("Hello world")




This section is empty.


View Source
var Default = New()

Default the default App


This section is empty.


type App

type App struct {
	ConfigFile string
	Config     *config.Config
	// contains filtered or unexported fields

App struct

func New

func New() *App

New return new App

func (*App) AddRouter

func (a *App) AddRouter(r ...*router.Router) *App

AddRouter Add Routers

func (*App) AddRouterGroup

func (a *App) AddRouterGroup(g ...*router.Group) *App

AddRouterGroup Add Group Routers

func (*App) Controller

func (a *App) Controller(c *App

Controller Route REST-ful Controller

func (*App) Delete

func (a *App) Delete(pattern string, handler func(ctx *context.Context)) *App

Delete Route Delete Method

func (*App) FSResource

func (a *App) FSResource(fs *embed.FS, pattern, file, contentType string) *App

FSResource Route a resource

func (*App) FaviconFS

func (a *App) FaviconFS(fs *embed.FS) *App

FaviconFS Use Favicon FS

func (*App) FaviconFile

func (a *App) FaviconFile(file string) *App

FaviconFile Use Favicon File

func (*App) FaviconRoute added in v1.0.4

func (a *App) FaviconRoute(route string) *App

FaviconRoute Use Favicon File

func (*App) Get

func (a *App) Get(pattern string, handler func(ctx *context.Context)) *App

Get Route Get Method

func (*App) Head

func (a *App) Head(pattern string, handler func(ctx *context.Context)) *App

Head Route Head Method

func (*App) Middlewares

func (a *App) Middlewares() []middleware.Middleware

Middlewares Filter Middlewares

func (*App) Options

func (a *App) Options(pattern string, handler func(ctx *context.Context)) *App

Options Route Options Method

func (*App) Patch

func (a *App) Patch(pattern string, handler func(ctx *context.Context)) *App

Patch Route Patch Method

func (*App) Post

func (a *App) Post(pattern string, handler func(ctx *context.Context)) *App

Post Route Post Method

func (*App) Put

func (a *App) Put(pattern string, handler func(ctx *context.Context)) *App

Put Route Put Method

func (*App) RecoveryConfig

func (a *App) RecoveryConfig(codeName string, codeVal int, msgName string) *App

RecoveryConfig Sets Recovery config

func (*App) RecoveryHandler

func (a *App) RecoveryHandler(handlers ...func(ctx *context.Context)) *App

RecoveryHandler Sets Recovery handler

func (*App) Request

func (a *App) Request(pattern string, handler func(ctx *context.Context)) *App

Request Route all Methods

func (*App) Resource

func (a *App) Resource(pattern, file, contentType string) *App

Resource Route a resource

func (*App) Route

func (a *App) Route(method, pattern string, handler func(ctx *context.Context)) *App

Route Route DIY Method

func (*App) Run

func (a *App) Run()

Run App

func (*App) Use

func (a *App) Use(middlewares ...middleware.Middleware) *App

Use Middlewares

func (*App) UseFavicon

func (a *App) UseFavicon() *App

UseFavicon Use Favicon Middleware

func (*App) UseLogger

func (a *App) UseLogger() *App

UseLogger Use Logger Middleware

func (*App) UseRecovery

func (a *App) UseRecovery() *App

UseRecovery Use Recovery Middleware

func (*App) UseSession

func (a *App) UseSession(provider session.Provider, config *session.Config, listener *session.Listener) *App

UseSession Use Session Middleware

func (*App) UseStatic

func (a *App) UseStatic(cache bool, root, prefix string) *App

UseStatic Use Static Resources Middleware

Jump to

Keyboard shortcuts

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