Goyave is a progressive and accessible web application framework focused on APIs, aimed at making development easy and enjoyable. It has a philosophy of cleanliness and conciseness to make programs more elegant, easier to maintain and more focused.
Goyave has an expressive, elegant syntax, a robust structure and conventions. Minimalist calls and reduced redundancy are among the Goyave's core principles. |
Develop faster and concentrate on the business logic of your application thanks to the many helpers and built-in functions. |
Goyave is accessible, yet powerful. The framework includes routing, request parsing, validation, localization, testing, authentication, and more! |
Most golang frameworks for web development don't have a strong directory structure nor conventions to make applications have a uniform architecture and limit redundancy. This makes it difficult to work with them on different projects. In companies, having a well-defined and documented architecture helps new developers integrate projects faster, and reduces the time needed for maintaining them. For open source projects, it helps newcomers understanding the project and makes it easier to contribute. With Goyave, expect a full package with minimum setup.
You can bootstrap your project using the Goyave template project. This project has a complete directory structure already set up for you.
$ curl https://raw.githubusercontent.com/System-Glitch/goyave/master/install.sh | bash -s my-project
> & ([scriptblock]::Create((curl "https://raw.githubusercontent.com/System-Glitch/goyave/master/install.ps1").Content)) -projectName my-project
Run go run my-project
in your project's directory to start the server, then try to request the hello
route.
$ curl http://localhost:8080/hello
Hi!
There is also an echo
route, with basic validation of query parameters.
$ curl http://localhost:8080/echo?text=abc%20123
abc 123
The example below shows a basic Hello world
application using Goyave.
import "github.com/System-Glitch/goyave/v2"
func registerRoutes(router *goyave.Router) {
router.Route("GET", "/hello", func(response *goyave.Response, request *goyave.Request) {
response.String(http.StatusOK, "Hello world!")
}, nil)
}
func main() {
goyave.Start(registerRoutes)
}
The Goyave framework has an extensive documentation covering in-depth subjects and teaching you how to run a project using Goyave from setup to deployment.
- Go 1.13+
- Go modules
Thank you for considering contributing to the Goyave framework! You can find the contribution guide in the documentation.
I have many ideas for the future of Goyave. I would be infinitely grateful to whoever want to support me and let me continue working on Goyave and making it better and better.
You can support also me on Patreon:
The Goyave framework is MIT Licensed. Copyright © 2019 Jérémy LAMBERT (SystemGlitch)