mirror of
https://github.com/astaxie/beego.git
synced 2025-02-02 07:27:11 +00:00
Silviu Capota-Mera
5a12b3d020
Add the ability to unregister fixed routes
Certain web application inherit most of the routes from a base application by using the underscore import (e.g. import _ "myoldapp.com/routers"). The new application might want to only overwrite certain pages, such as "/about" or "/faq" The proposed new UnregisterFixedRoute method allows unregistering of the specified paths. Usage (replace "GET" with "*" for all methods): beego.UnregisterFixedRoute("/yourpreviouspath", "GET") beego.Router("/yourpreviouspath", yourControllerAddress, "get:GetNewPage") The children paths are left intact. For example, /yourpreviouspath/oldchildsubpath should still continue to function in legacy mode.
Beego
beego is used for rapid development of RESTful APIs, web apps and backend services in Go. It is inspired by Tornado, Sinatra and Flask. beego has some Go-specific features such as interfaces and struct embedding.
More info at beego.me.
Quick Start
Download and install
go get github.com/astaxie/beego
Create file hello.go
package main
import "github.com/astaxie/beego"
func main(){
beego.Run()
}
Build and run
go build hello.go
./hello
Go to http://localhost:8080
Congratulations! You've just built your first beego app.
Please see Documentation for more.
Features
- RESTful support
- MVC architecture
- Modularity
- Auto API documents
- Annotation router
- Namespace
- Powerful development tools
- Full stack for Web & API
Documentation
Community
- http://beego.me/community
- Welcome to join us in Slack: https://beego.slack.com, you can get invited from here
License
beego source code is licensed under the Apache Licence, Version 2.0 (http://www.apache.org/licenses/LICENSE-2.0.html).
Description
Languages
Go
99.6%
Shell
0.4%