pub fn cacheable(m: Method) bool
A cacheable response can be stored to be retrieved and used later, saving a new request to the server.
https://developer.mozilla.org/en-US/docs/Glossary/cacheable
https://datatracker.ietf.org/doc/html/rfc7231#section-4.2.3
m: Method
87 88 89 90 91 92
pub fn cacheable(m: Method) bool { return switch (m) { .GET, .HEAD, .QUERY => true, .POST, .PUT, .DELETE, .CONNECT, .OPTIONS, .TRACE, .PATCH => false, }; }
A cacheable response can be stored to be retrieved and used later, saving a new request to the server.
https://developer.mozilla.org/en-US/docs/Glossary/cacheable
https://datatracker.ietf.org/doc/html/rfc7231#section-4.2.3