Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

mojixcoder/kid

Repository files navigation

test code quality coverage

Kid Micro Web Framework


Kid is a micro web framework written in Go. It aims to keep its core simple and yet powerful. It's fully compatible with net/http interfaces and can be adapted with other net/http compatible packages as well.

Features


  • Robust tree-based router.
  • Path parameters.
  • Router groups.
  • Rich built-in responses(JSON, HTML, XML, string, byte).
  • Middlewares.
  • Zero dependency, only standard library.
  • Compatible with net/http interfaces.
  • Extendable, you can also use your own JSON, XML serializers or HTML renderer.

Versioning


This package follows semver versioning.

Quick Start


To install Kid Go 1.21 or higher is required: go get github.com/mojixcoder/kid

Create server.go:

package main
import (
 "net/http"
 "github.com/mojixcoder/kid"
)
func main() {
 k := kid.New()
 k.Get("/hello", helloHandler)
 k.Run()
}
func helloHandler(c *kid.Context) {
 c.JSON(http.StatusOK, kid.Map{"message": "Hello Kid!"})
}

About

Kid is a micro web framework written in Go.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

AltStyle によって変換されたページ (->オリジナル) /