Merge pull request #7 from gin-contrib/new

Updates README
This commit is contained in:
Javier Provecho Fernandez 2016-10-31 09:50:56 +01:00 committed by GitHub
commit 0202b02ec3
2 changed files with 16 additions and 2 deletions

View File

@ -11,6 +11,20 @@ Gin middleware/handler to enable CORS support.
## Usage
### Start using it
1. Download and install it:
```sh
$ go get gopkg.in/gin-contrib/cors.v1
```
2. Import it in your code:
```go
import "gopkg.in/gin-contrib/cors.v1"
```
### Canonical example:
```go
@ -19,7 +33,7 @@ package main
import (
"time"
"github.com/gin-contrib/cors"
"gopkg.in/gin-contrib/cors.v1"
"gopkg.in/gin-gonic/gin.v1"
)

View File

@ -3,7 +3,7 @@ package main
import (
"time"
"github.com/gin-contrib/cors"
"gopkg.in/gin-contrib/cors.v1"
"gopkg.in/gin-gonic/gin.v1"
)