Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document features automatically. #2780

Merged
merged 5 commits into from Jul 18, 2022
Merged

Conversation

futursolo
Copy link
Member

Description

This pull request enables the doc_auto_cfg feature which documents the required feature flags automatically.

However, if an item is re-exported with pub use, it's not documented automatically unless the item itself has a #[doc(cfg(...))] or #[cfg(...)]. I have modified those to use #[cfg(...)] instead of #[doc(cfg(...))].

Checklist

  • I have reviewed my own code
  • I have added tests

@futursolo futursolo added documentation A-yew Area: The main yew crate labels Jul 18, 2022
github-actions[bot]
github-actions bot previously approved these changes Jul 18, 2022
@github-actions
Copy link

github-actions bot commented Jul 18, 2022

Visit the preview URL for this PR (updated for commit 3593765):

https://yew-rs-api--pr2780-doc-auto-cfg-a61n4l48.web.app

(expires Mon, 25 Jul 2022 04:48:17 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

@github-actions
Copy link

github-actions bot commented Jul 18, 2022

Size Comparison

examples master (KB) pull request (KB) diff (KB) diff (%)
boids 173.452 173.449 -0.003 -0.002%
contexts 110.150 110.139 -0.012 -0.011%
counter 87.038 87.035 -0.003 -0.003%
counter_functional 87.704 87.702 -0.002 -0.002%
dyn_create_destroy_apps 90.148 90.147 -0.001 -0.001%
file_upload 103.506 103.503 -0.003 -0.003%
function_memory_game 168.673 168.671 -0.002 -0.001%
function_router 353.465 353.471 +0.006 +0.002%
function_todomvc 162.419 162.413 -0.006 -0.004%
futures 226.105 226.105 0 0.000%
game_of_life 107.727 107.725 -0.002 -0.002%
immutable 210.050 210.051 +0.001 +0.000%
inner_html 84.058 84.056 -0.002 -0.002%
js_callback 113.382 113.382 0 0.000%
keyed_list 195.879 195.874 -0.005 -0.002%
mount_point 86.681 86.681 0 0.000%
nested_list 116.269 116.265 -0.004 -0.003%
node_refs 93.981 93.981 0 0.000%
password_strength 1547.363 1547.365 +0.002 +0.000%
portals 97.874 97.871 -0.003 -0.003%
router 321.391 321.399 +0.009 +0.003%
simple_ssr 154.938 154.938 +0.001 +0.001%
ssr_router 399.949 399.668 -0.281 -0.070%
suspense 111.042 111.038 -0.004 -0.004%
timer 89.763 89.760 -0.003 -0.003%
todomvc 143.399 143.396 -0.003 -0.002%
two_apps 87.694 87.691 -0.003 -0.003%
web_worker_fib 154.721 154.710 -0.011 -0.007%
webgl 87.947 87.948 +0.001 +0.001%

✅ None of the examples has changed their size significantly.

github-actions[bot]
github-actions bot previously approved these changes Jul 18, 2022
Copy link
Member

@WorldSEnder WorldSEnder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice to see that this is finally possible with cargo doc

@futursolo futursolo merged commit 6f53a4e into yewstack:master Jul 18, 2022
@futursolo futursolo deleted the doc-auto-cfg branch December 15, 2022 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-yew Area: The main yew crate documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants