Releases: go-chi/chi
Releases · go-chi/chi
v5.1.0
What's Changed
- middleware: add Discard method to WrapResponseWriter by @patrislav in #926
- Adds
Discard()
method to themiddleware.WrapResponseWriter
interface. This is technically an API breaking change. However after some discussion at #926 (comment), we decided to move forward, and release as minor version, as we don't expect anyone to rely on this interface / implement it externally.
- Adds
New Contributors
- @patrislav made their first contribution in #926
Full Changelog: v5.0.14...v5.1.0
v5.0.14
What's Changed
- middleware: fix typo in RealIP doc by @l2dy in #903
- reduce size of Context struct from 216 bytes to 208 bytes by @juburr in #912
- Avoid possible memory leak in compress middleware by @Neurostep in #919
- docs: Update stale links in docs for contributing by @Lutherwaves in #904
- Revert "Avoid possible memory leak in compress middleware" by @VojtechVitek in #924
New Contributors
- @l2dy made their first contribution in #903
- @juburr made their first contribution in #912
- @Neurostep made their first contribution in #919
- @Lutherwaves made their first contribution in #904
Full Changelog: v5.0.12...v5.0.14
v5.0.13
What's Changed
- middleware: fix typo in RealIP doc by @l2dy in #903
- reduce size of Context struct from 216 bytes to 208 bytes by @juburr in #912
- Avoid possible memory leak in compress middleware by @Neurostep in #919
New Contributors
- @l2dy made their first contribution in #903
- @juburr made their first contribution in #912
- @Neurostep made their first contribution in #919
Full Changelog: v5.0.12...v5.0.13
v5.0.12
Hi everyone, thank you to all contributors + reviewers.
We present chi v5.0.12 which includes support for the new Go 1.22 mux routing features :)
Specifically, this release adds support for:
- Routing methods
r.Handle("GET /users/{userID}", handler)
and similarly inr.HandlerFunc
with a very simple addition to chi, thank you @Spartan09 and @angelofallars for their work on the PRs to add support (#897, #901) - Access url path parameters via
request.PathValue("xyz")
andrequest.PathValue("*")
on*http.Request
when using the chi router in Go 1.22+. Of course you may also usechi.URLParam(r, "xyz")
andchi.URLParam(r, "*")
– these are all equivalent now in Go 1.22+. Thank you @angelofallars for the PR (#901) - For full list of changes, see v5.0.11...v5.0.12
v5.0.11
Thank you again to all contributors and reviewers :)
- docs updates
- go 1.21 in ci
- typos in comments
- middleware: Sunset, middleware which can be used to deprecate an endpoint (#844)
- middleware: use original expvar handler for profiler middleware (#848)
- updated _examples/httplog to use "log/slog" in go 1.21+
- middleware: new SuppressNotFound
- ensure to reset methodsAllowed between requests (9dd8b4a)
- History of changes, see v5.0.10...v5.0.11
v5.0.10
Thank you to all contributors and reviewers :)
- Use timestamps in GMT format per RFC2616 -- #772
- Update logging example to use preview version of new log/slog -- #771
- Fix duplicate fields in logging example -- #779
- chore: recoverer middleware skip write header on upgrade connection -- #795
- Request size middleware -- #809
- middleware.Compress: implement Unwrap() method to the compressResponseWriter -- #819
- Adds the Allow header on 405 response -- #776
- History of changes, see: v5.0.9...v5.0.10
v5.0.9
- History of changes, see: v5.0.8...v5.0.9
v5.0.8
v5.0.7
- middleware.RealIP - add support for True-Client-IP header
- History of changes, see: v5.0.6...v5.0.7
v5.0.6
- Introduce simple util middleware.Maybe
- History of changes, see: v5.0.5...v5.0.6