Add clarification on using versionadded / versionchanged directives

pull/12453/head
Matt Westcott 2024-10-22 19:01:24 +01:00 zatwierdzone przez Matt Westcott
rodzic c1ce58fb42
commit 4d31bd0a29
1 zmienionych plików z 3 dodań i 1 usunięć

Wyświetl plik

@ -360,7 +360,7 @@ Only use tables when needed, using the [GitHub Flavored Markdown table syntax](h
### Version added, changed, deprecations
Sphinx offers release-metadata directives to generate this information consistently. Use as appropriate.
Sphinx offers release-metadata directives to present information about new or updated features in a consistent manner.
```{versionadded} 2.15
```
@ -382,6 +382,8 @@ Sphinx offers release-metadata directives to generate this information consisten
</details>
These directives will typically be removed two releases after they are added, so should only be used for short-lived information, such as "The `WAGTAILIMAGES_CACHE_DURATION` setting was added". Detailed documentation about the feature should be in the main body of the text, outside of the directive.
### Progressive disclosure
We can add supplementary information in documentation with the HTML `<details>` element. This relies on HTML syntax, which can be hard to author consistently, so keep this type of formatting to a minimum.