Versions in this module Expand all Collapse all v1 v1.0.1 May 21, 2021 Changes in this version + type CacheEntry struct + Body []byte + Header http.Header + StatusCode int + func (c *CacheEntry) Decode(b []byte) error + func (c *CacheEntry) Encode() ([]byte, error) + func (c *CacheEntry) Replay(w http.ResponseWriter) error type Config + StatusCode []int v1.0.0 May 19, 2021 Changes in this version + func New(cfg *Config, cache *freecache.Cache) echo.MiddlewareFunc + type CacheMiddleware struct + func (m *CacheMiddleware) Handler(next echo.HandlerFunc) echo.HandlerFunc + type Config struct + Cache func(r *http.Request) bool + IgnoreQuery bool + Methods []string + Refresh func(r *http.Request) bool + TTL time.Duration + type ResponseRecorder struct + func NewResponseRecorder(w http.ResponseWriter) *ResponseRecorder + func (r *ResponseRecorder) Result() ([]byte, error) + func (w *ResponseRecorder) Write(b []byte) (int, error) + func (w *ResponseRecorder) WriteHeader(statusCode int)