WithAppConfig constructs a *http.Request which has the provided app config attached.
(r *http.Request, cfg any)
| 166 | |
| 167 | // WithAppConfig constructs a *http.Request which has the provided app config attached. |
| 168 | func WithAppConfig(r *http.Request, cfg any) *http.Request { |
| 169 | return r.WithContext(context.WithValue(r.Context(), appConfigKey, cfg)) |
| 170 | } |
| 171 | |
| 172 | type pageDataKeyType struct{} |
| 173 |
no test coverage detected