Documentation for derive macros is in the wrong place
- Dominant language
- Rust
- Stars
- 48.2k
- Forks
- 4.8k
- Avg merge
- 3d 16h
- Merged PRs (30d)
- 171
Description
## How can Bevy's documentation be improved?
For derivable traits such as `WorldQuery`, `SystemParam`, `Bundle`, etc., documentation for the derive macro is placed on the [trait definition](https://github.com/bevyengine/bevy/blob/6b75589e2c91429eb6c35574840d47d39b2379b9/crates/bevy_ecs/src/query/fetch.rs#L46) itself, rather than the derive macro. This means that when hovering over a `#[derive(WorldQuery)]` attribute, it appears to be [mostly undocumented](https://github.com/bevyengine/bevy/blob/6b75589e2c91429eb6c35574840d47d39b2379b9/crates/bevy_ecs/macros/src/lib.rs#L403).
Any documentation regarding the derive macro should be moved *to* the derive macro -- this information is not relevant to consumers of the trait, and is not discoverable for those trying to derive it.
Contributor guide
Research direction
Compare the derive-related documentation in crates/bevy_ecs/src/query/fetch.rs with the derive macro documentation in crates/bevy_ecs/macros/src/lib.rs, including WorldQuery, SystemParam, and Bundle. Move the macro-specific guidance so it appears on the derive macros and verify that trait documentation remains focused on the traits while hovering over each derive attribute shows the relevant information.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100