forked from orbit-oss/flask
Updated the documentation to show how to set cookies for not yet existing responses
This commit is contained in:
parent
7331ae3df5
commit
b40af3ccd9
3 changed files with 78 additions and 0 deletions
|
|
@ -621,6 +621,10 @@ just return strings from the view functions Flask will convert them into
|
|||
response objects for you. If you explicitly want to do that you can use
|
||||
the :meth:`~flask.make_response` function and then modify it.
|
||||
|
||||
Sometimes you might want to set a cookie at a point where the response
|
||||
object does not exist yet. This is possible by utilizing the
|
||||
:ref:`deferred-callbacks` pattern.
|
||||
|
||||
For this also see :ref:`about-responses`.
|
||||
|
||||
Redirects and Errors
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue