mirror of
https://github.com/django/django.git
synced 2024-12-22 17:16:24 +00:00
Fixed #21154 -- Updated TemplateResponse docs to better explain context.
Thanks mrmachine for the report.
This commit is contained in:
parent
728548e483
commit
c39c9f2ad8
@ -132,10 +132,10 @@ TemplateResponse objects
|
||||
|
||||
.. class:: TemplateResponse()
|
||||
|
||||
TemplateResponse is a subclass of
|
||||
:class:`~django.template.response.SimpleTemplateResponse` that uses
|
||||
a :class:`~django.template.RequestContext` instead of
|
||||
a :class:`~django.template.Context`.
|
||||
``TemplateResponse`` is a subclass of
|
||||
:class:`~django.template.response.SimpleTemplateResponse` that uses
|
||||
a :class:`~django.template.RequestContext` instead of
|
||||
a :class:`~django.template.Context`.
|
||||
|
||||
Methods
|
||||
-------
|
||||
@ -155,7 +155,9 @@ Methods
|
||||
``context``
|
||||
A dictionary of values to add to the template context. By default,
|
||||
this is an empty dictionary. :class:`~django.template.Context` objects
|
||||
are also accepted as ``context`` values.
|
||||
are also accepted as ``context`` values. If you pass a
|
||||
:class:`~django.template.Context` instance or subclass, it will be used
|
||||
instead of creating a new :class:`~django.template.RequestContext`.
|
||||
|
||||
``status``
|
||||
The HTTP Status code for the response.
|
||||
|
Loading…
Reference in New Issue
Block a user