codegangsta/martini-contrib — pull request #23 by Archs (2013-11-27 08:08:19+00:00)
Title: Add web.go's web.Context for Martini

# web.Context
[hoisie][] [web.go][]'s Context for Martini.

[hoisie]:https://github.com/hoisie
[web.go]:https://github.com/hoisie/web

[API Reference](http://godoc.org/github.com/Archs/martini-contrib/web)

## Description
`web.Context` provides a [web.go][] compitable layer for reusing the code written with
hoisie's `web.go` framework. Here compitable means we can use `web.Context` the same
way as in hoisie's `web.go` but not the others.

## Usage

~~~ go
package main

import (
"github.com/codegangsta/martini"
"github.com/Archs/martini-contrib/web"
)

func main() {
m := martini.Classic()
m.Use(web.ContextWithCookieSecret())

m.Post("/hello", func(ctx *web.Context){
ctx.WriteString("Hello World!")
})

m.Run()
}
~~~