feat: add `#[allow(missing_docs)]` to `children` prop in components (#934)

This commit is contained in:
Roland Fredenhagen 2023-04-23 21:34:42 +02:00 committed by GitHub
parent d2e3a156e8
commit c471986024
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 0 deletions

View File

@ -458,10 +458,18 @@ fn prop_builder_fields(vis: &Visibility, props: &[Prop]) -> TokenStream {
let builder_docs = prop_to_doc(prop, PropDocStyle::Inline);
// Children won't need documentation in many cases
let allow_missing_docs = if name.ident == "children" {
quote!(#[allow(missing_docs)])
} else {
quote!()
};
quote! {
#docs
#builder_docs
#builder_attrs
#allow_missing_docs
#vis #name: #ty,
}
})