mirror of https://github.com/tiangolo/fastapi.git
📝 Fix renamed parameter `content_type` typo (#2135)
This commit is contained in:
parent
1a000d7e5f
commit
730ded2870
|
|
@ -40,7 +40,7 @@ Import the `Response` class (sub-class) you want to use and declare it in the *p
|
|||
To return a response with HTML directly from **FastAPI**, use `HTMLResponse`.
|
||||
|
||||
* Import `HTMLResponse`.
|
||||
* Pass `HTMLResponse` as the parameter `content_type` of your *path operation*.
|
||||
* Pass `HTMLResponse` as the parameter `response_class` of your *path operation decorator*.
|
||||
|
||||
```Python hl_lines="2 7"
|
||||
{!../../../docs_src/custom_response/tutorial002.py!}
|
||||
|
|
|
|||
Loading…
Reference in New Issue