📝 Update documentation to refer to list instead of List (#1147)

Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
Co-authored-by: svlandeg <svlandeg@github.com>
This commit is contained in:
bubbletroubles
2025-03-01 00:58:52 +11:00
committed by GitHub
parent a82c3fe964
commit 1bd5f27ed4
5 changed files with 8 additions and 8 deletions

View File

@@ -38,7 +38,7 @@ For example, we can pass the same `Hero` **SQLModel** class (because it is also
We can also use other type annotations, the same way we can use with Pydantic fields. For example, we can pass a list of `Hero`s.
First, we import `List` from `typing` and then we declare the `response_model` with `List[Hero]`:
To do so, we declare the `response_model` with `list[Hero]`:
{* ./docs_src/tutorial/fastapi/response_model/tutorial001_py310.py ln[40:44] hl[40] *}