{"id":48593439,"url":"https://github.com/orian/wctx","last_synced_at":"2026-04-08T20:54:12.689Z","repository":{"id":57598905,"uuid":"44104029","full_name":"orian/wctx","owner":"orian","description":"A httprouter with golang.org/x/net/context support.","archived":false,"fork":false,"pushed_at":"2016-04-18T19:12:46.000Z","size":5,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-04-08T20:54:05.702Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/orian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-10-12T11:48:06.000Z","updated_at":"2016-04-26T10:55:26.000Z","dependencies_parsed_at":"2022-08-30T04:41:14.295Z","dependency_job_id":null,"html_url":"https://github.com/orian/wctx","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/orian/wctx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orian%2Fwctx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orian%2Fwctx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orian%2Fwctx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orian%2Fwctx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/orian","download_url":"https://codeload.github.com/orian/wctx/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orian%2Fwctx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31573788,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-08T14:31:17.711Z","status":"ssl_error","status_checked_at":"2026-04-08T14:31:17.202Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-04-08T20:54:08.181Z","updated_at":"2026-04-08T20:54:12.676Z","avatar_url":"https://github.com/orian.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# With ConTeXt\n[![GoDoc](http://godoc.org/github.com/orian/wctx?status.png)](http://godoc.org/github.com/orian/wctx)\n\nIt's a `github.com/julienschmidt/httprouter` drop in replacement. Basically all methods from the original library are wrapped.\nIt makes easy to us the `httprouter` on App Engine and outside of App Engine.\n\nThe problem with App Engine context is that it requires your app to hardcode the `appengine.NewContext` in\nyour handlers. As stated in https://blog.golang.org/context inside Google's infrastructure\nthey pass Context around. It's pretty useful for puting timeouts and other limits on a request\nand passing user permissions.\n\nOn App Engine the init code would look:\n\n```go\nfunc SomeHandler(c context.Context, w http.ResponseWriter, r *http.Request) { /* some code */ }\n\nfunc GaeContext(r *http.Request) context.Context {\n\treturn appengine.NewContext(r)\n}\n\nfunc init() {\n\tr := New()\n\tr.ContextFactory = GaeContext\n\tr.GET(\"/page/:pageid/:mod\", SomeHandler)\n\thttp.Handler(\"\", r)  // r may be replaced by r.R, the underlaying httprouter.\n}\n```\n\nFor more details please the doc of the original repo: [![GoDoc](http://godoc.org/github.com/julienschmidt/httprouter?status.png)](http://godoc.org/github.com/julienschmidt/httprouter)\n\nThe extra useful method indluce:\n```\nfunc (r *Router) WithMiddleware(m Middleware) *Router\n```\nthe returned Router keeps the underlying httprouter.Router but extends the\ncurrently registered middlewares by passed generator.\n\nUnder the hood it keeps all added Middleware generators in list and builds\nthe desired handle method when one adds a path to be handled.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Forian%2Fwctx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Forian%2Fwctx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Forian%2Fwctx/lists"}