RtcPeerConnection::set_local_description generated documentation for required features is wrong #1569
Labels
bug
docs
Issues related to documentation
frontend:webidl
Issues related to the WebIDL frontend to wasm-bindgen
web-sys
Issues related to the `web-sys` crate
Describe the Bug
RtcPeerConnection::set_local_description docs say that the features required to use it are RtcPeerConnection and RtcSessionDescriptionInit, but it will not work without also enabling "RtcSdpType".
Also, the "RtcSessionDescriptionInit" type is not generated at all without enabling "RtcSdpType". I don't know why this is, but it might have something to do with RtcSessionDescriptionInit::new taking an RtcSdpType?
I had to do a lot of trial and error to figure out which missing feature was required (copying the entire set of Rtc* features and bisecting.
Steps to Reproduce
Expected Behavior
I would expect RtcSessionDescriptionInit to only require the feature which is the name of its type, and I would also expect the docs for RtcPeerConnection::set_local_description to mention all required features.
Actual Behavior
They do not, and you have to bisect the entire list of available features to find which one is missing, or know what might have gone wrong. Is there a better way to discover what features are actually required for a type / method other than the generated documentation in case it goes wrong?
The text was updated successfully, but these errors were encountered: