From a89bf0d4002c9df5a5b0ef095a1bf9cd6c23b345 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=93=E6=99=BA=E6=9D=B0?= Date: Sat, 22 Apr 2017 12:21:30 +0800 Subject: [PATCH] Update README.md --- README.md | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 82ea6a58..c7f5fda2 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ - -#Gin Web Framework +# Gin Web Framework [![Build Status](https://travis-ci.org/gin-gonic/gin.svg)](https://travis-ci.org/gin-gonic/gin) @@ -81,7 +80,6 @@ BenchmarkZeus_GithubAll | 2000 | 944234 | 300688 | 2648 - [x] Battle tested - [x] API frozen, new releases will not break your code. - ## Start using it 1. Download and install it: @@ -153,6 +151,7 @@ func main() { ``` #### Querystring parameters + ```go func main() { router := gin.Default() @@ -247,6 +246,7 @@ func main() { ``` #### Grouping routes + ```go func main() { router := gin.Default() @@ -285,8 +285,8 @@ instead of r := gin.Default() ``` - #### Using middleware + ```go func main() { // Creates a router without any middleware by default @@ -371,8 +371,8 @@ func main() { } ``` +### Multipart/Urlencoded binding -###Multipart/Urlencoded binding ```go package main @@ -410,7 +410,6 @@ Test it with: $ curl -v --form user=user --form password=password http://localhost:8080/login ``` - #### XML, JSON and YAML rendering ```go @@ -543,7 +542,6 @@ func main() { } ``` - #### Redirects Issuing a HTTP redirect is easy: @@ -597,6 +595,7 @@ func main() { ``` #### Using BasicAuth() middleware + ```go // simulate some private data var secrets = gin.H{ @@ -634,8 +633,8 @@ func main() { } ``` - #### Goroutines inside a middleware + When starting inside a middleware or handler, you **SHOULD NOT** use the original context inside it, you have to use a read-only copy. ```go @@ -731,3 +730,4 @@ Awesome project lists using [Gin](https://github.com/gin-gonic/gin) web framewor * [drone](https://github.com/drone/drone): Drone is a Continuous Delivery platform built on Docker, written in Go * [gorush](https://github.com/appleboy/gorush): A push notification server written in Go. +