Skip to content

Commit

Permalink
Add documentation for warning blocks in rustdoc book
Browse files Browse the repository at this point in the history
  • Loading branch information
GuillaumeGomez committed Aug 14, 2023
1 parent d51521e commit 57d2b84
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/doc/rustdoc/src/how-to-write-documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,18 @@ characters:

So, no need to manually enter those Unicode characters!

### Adding a warning block

If you want to make a "warning" stand out in the documentation, you can wrap it like this:

```md
/// documentation
///
/// <div class="warning">A big warning!</div>
///
/// more documentation
```

[`backtrace`]: https://docs.rs/backtrace/0.3.50/backtrace/
[commonmark markdown specification]: https://commonmark.org/
[commonmark quick reference]: https://commonmark.org/help/
Expand Down

0 comments on commit 57d2b84

Please sign in to comment.