Open nakedible-p opened 1 year ago
The documentation for the crate does not specify what is the common way to use this crate - it only explains how to extend it for new headers.
It took a bit of trial and error until I finally found the trait HeaderMapExt. And even that trait isn't documented.
HeaderMapExt
The documentation should have something like:
use headers::HeaderMapExt; let mut headers = HeaderMap::new(); headers.typed_insert(Upgrade::websocket()); let ws = headers.typed_get::<Upgrade>();
The documentation for the crate does not specify what is the common way to use this crate - it only explains how to extend it for new headers.
It took a bit of trial and error until I finally found the trait
HeaderMapExt
. And even that trait isn't documented.The documentation should have something like: