{"id":57274,"library":"darling","title":"Darling","description":"A proc-macro library for reading attributes into structs when implementing custom derives.","status":"active","version":"0.23.0","language":"rust","source_language":null,"source_url":"https://github.com/TedDriggs/darling","tags":["proc-macro","derive","attributes","parsing"],"install":[{"cmd":"# Cargo.toml\n[dependencies]\ndarling = \"0.23.0\"","lang":"toml","label":"Cargo.toml"},{"cmd":"cargo add darling","lang":"bash","label":"cargo add"}],"dependencies":[],"imports":[{"symbol":"FromDeriveInput","correct":"use darling::FromDeriveInput;"}],"quickstart":{"code":"use darling::FromDeriveInput;\nuse syn::DeriveInput;\n\n#[derive(FromDeriveInput)]\n#[darling(attributes(my_attr))]\nstruct MyOptions {\n    name: String,\n    count: Option<usize>,\n}\n\nfn main() {\n    let input: DeriveInput = syn::parse_str(\"#[derive(MyTrait)] #[my_attr(name = \\\"test\\\")] struct Foo;\").unwrap();\n    let opts = MyOptions::from_derive_input(&input).unwrap();\n    println!(\"Name: {}\", opts.name);\n}","lang":"rust","description":"Parses custom derive attributes into a struct."},"warnings":[{"fix":"Familiarize with syn and quote crates for derive macros.","message":"Requires understanding of proc-macro and syn crate.","severity":"gotcha","affected_versions":">=0.10.0"}],"env_vars":null,"search_vec":"'attribut':9,20 'custom':14 'darl':1 'deriv':15,19 'implement':13 'librari':6 'macro':5,18 'pars':21 'proc':4,17 'proc-macro':3,16 'read':8 'struct':11","created_at":"2026-06-16T15:35:47.175778+00:00","updated_at":"2026-06-16T15:35:47.175778+00:00","problems":[],"ecosystem":"crates","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/TedDriggs/darling","github":"https://github.com/TedDriggs/darling","docs":"https://docs.rs/darling/","changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["other"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-16","next_check":"2026-12-13","install_tag":null}}