| commit | 832c3302f7f176d1992b2656a07ad0c22125d03b | [log] [tgz] |
|---|---|---|
| author | Android Build Coastguard Worker <[email protected]> | Fri Feb 09 00:12:04 2024 +0000 |
| committer | Android Build Coastguard Worker <[email protected]> | Fri Feb 09 00:12:04 2024 +0000 |
| tree | a368009a1a38e5ff9feff8a33f59d8e6d214f194 | |
| parent | e5601e64f912c0e4f150ba07b671543b41338dac [diff] | |
| parent | ec2e7d7a609d03cd0f56db9fa445c6324736521c [diff] |
Snap for 11426397 from ec2e7d7a609d03cd0f56db9fa445c6324736521c to 24Q2-release Change-Id: I16213ffc94d60ce9b9cf7760c15e1710e3ea0887
This crate provides a macro that extracts documentation comments from Cargo.toml
To use this crate, add #![doc = document_features::document_features!()] in your crate documentation. The document_features!() macro reads your Cargo.toml file, extracts feature comments and generates a markdown string for your documentation.
Use ## and #! comments in your Cargo.toml to document features, for example:
[dependencies] document-features = "0.2" ## ... [features] ## The foo feature enables the `foo` functions foo = [] ## The bar feature enables the [`bar`] module bar = [] #! ### Experimental features #! The following features are experimental ## Activate the fusion reactor fusion = []
These comments keep the feature definition and documentation next to each other, and they are then rendered into your crate documentation.
Check out the documentation for more details.
Contributions are welcome. We accept pull requests and bug reports.
MIT OR Apache-2.0