docs: update docs and CHANGES.rst

This commit is contained in:
kadai0308 2025-05-26 17:29:59 +08:00
parent 45a0ff357f
commit 0abda4d277
2 changed files with 6 additions and 1 deletions

View File

@ -5,6 +5,7 @@ Unreleased
- Drop support for Python 3.9. :pr:`5730`
- Remove previously deprecated code: ``__version__``. :pr:`5648`
- Support for using @app.template_filter, @app.template_test, and @app.template_global decorators without parentheses. :pr:`5736`
Version 3.1.1

View File

@ -145,7 +145,11 @@ that. You can either put them by hand into the
:attr:`~flask.Flask.jinja_env` of the application or use the
:meth:`~flask.Flask.template_filter` decorator.
The two following examples work the same and both reverse an object::
The following examples work the same and all reverse an object::
@app.template_filter # use the function name as filter name
def reverse_filter(s):
return s[::-1]
@app.template_filter('reverse')
def reverse_filter(s):