]> git.ipfire.org Git - thirdparty/fastapi/fastapi.git/commitdiff
📝 Update includes in `docs/en/docs/tutorial/response-status-code.md` (#12620)
authorQuentin Takeda <quentin.vadon@gmail.com>
Mon, 28 Oct 2024 11:13:18 +0000 (12:13 +0100)
committerGitHub <noreply@github.com>
Mon, 28 Oct 2024 11:13:18 +0000 (11:13 +0000)
docs/en/docs/tutorial/response-status-code.md

index 73af62aed7186d1c7fff572ccd835c6fd91d6987..a32faa40b20dea217f3b473383bdbb427963e620 100644 (file)
@@ -8,9 +8,7 @@ The same way you can specify a response model, you can also declare the HTTP sta
 * `@app.delete()`
 * etc.
 
-```Python hl_lines="6"
-{!../../docs_src/response_status_code/tutorial001.py!}
-```
+{* ../../docs_src/response_status_code/tutorial001.py hl[6] *}
 
 /// note
 
@@ -76,9 +74,7 @@ To know more about each status code and which code is for what, check the <a hre
 
 Let's see the previous example again:
 
-```Python hl_lines="6"
-{!../../docs_src/response_status_code/tutorial001.py!}
-```
+{* ../../docs_src/response_status_code/tutorial001.py hl[6] *}
 
 `201` is the status code for "Created".
 
@@ -86,9 +82,7 @@ But you don't have to memorize what each of these codes mean.
 
 You can use the convenience variables from `fastapi.status`.
 
-```Python hl_lines="1  6"
-{!../../docs_src/response_status_code/tutorial002.py!}
-```
+{* ../../docs_src/response_status_code/tutorial002.py hl[1,6] *}
 
 They are just a convenience, they hold the same number, but that way you can use the editor's autocomplete to find them: