Skip to content

Conversation

@browniebroke
Copy link
Member

@browniebroke browniebroke commented Dec 9, 2025

Description

Use admonition markdown extension to improve callout for warnings in our docs. The extension was already installed but warnings weren't styled.

Why?

This came up in #9823, where the warning was initially added with a slightly different syntax that our existing ones. Also, I think it doesn't stand out very much in the page:

image

---

**Warning**: If you require cross-domain AJAX requests, you should generally be using the more modern approach of [CORS][cors] as an alternative to `JSONP`. See the [CORS documentation][cors-docs] for more details.
!!! warning
Copy link
Member Author

Choose a reason for hiding this comment

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

Image


**Warning**: Always use Django's standard login view when creating login pages. This will ensure your login views are properly protected.
!!! warning
Always use Django's standard login view when creating login pages. This will ensure your login views are properly protected.
Copy link
Member Author

Choose a reason for hiding this comment

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

Image


**Warning**: Do not use `.as_view()` with `@action` methods. It bypasses router setup and may ignore action settings like `permission_classes`. Use `DefaultRouter` for actions.
!!! warning
Do not use `.as_view()` with `@action` methods. It bypasses router setup and may ignore action settings like `permission_classes`. Use `DefaultRouter` for actions.
Copy link
Member Author

Choose a reason for hiding this comment

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

Image

@browniebroke
Copy link
Member Author

There are 19 similar occurrences of **Note** which could be updated in a same way

@browniebroke browniebroke requested a review from auvipy December 9, 2025 09:09
Copy link
Collaborator

@peterthomassen peterthomassen left a comment

Choose a reason for hiding this comment

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

cool!

@browniebroke browniebroke merged commit 3a70eb2 into encode:main Dec 9, 2025
7 checks passed
@browniebroke browniebroke deleted the docs-admonition-styles branch December 9, 2025 13:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants