mirror of
https://github.com/rjNemo/fastapi
synced 2026-06-11 21:16:45 +00:00
📝 Add example screenshot for dependencies
This commit is contained in:
parent
b79c13baed
commit
471c9cfc2d
2 changed files with 1 additions and 4 deletions
Binary file not shown.
|
Before Width: | Height: | Size: 104 KiB After Width: | Height: | Size: 65 KiB |
|
|
@ -130,12 +130,9 @@ commons = Depends(CommonQueryParams)
|
||||||
{!./src/dependencies/tutorial003.py!}
|
{!./src/dependencies/tutorial003.py!}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
But declaring the type is encouraged as that way your editor will know what will be passed as the parameter `commons`, and then it can help you with code completion, type checks, etc:
|
But declaring the type is encouraged as that way your editor will know what will be passed as the parameter `commons`, and then it can help you with code completion, type checks, etc:
|
||||||
|
|
||||||
```Python hl_lines="19 20 21"
|
<img src="/img/tutorial/dependencies/image02.png">
|
||||||
{!./src/dependencies/tutorial002.py!}
|
|
||||||
```
|
|
||||||
|
|
||||||
## Shortcut
|
## Shortcut
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue