- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for recommended (0.46 sec)
-
docs/en/docs/tutorial/query-params-str-validations.md
```Python q: Annotated[str, Query()] = "rick" ``` ...or in older code bases you will find: ```Python q: str = Query(default="rick") ``` ### Advantages of `Annotated` **Using `Annotated` is recommended** instead of the default value in function parameters, it is **better** for multiple reasons. π€ The **default** value of the **function parameter** is the **actual default** value, that's more intuitive with Python in general. π
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Mar 22 01:42:11 GMT 2024 - 25.7K bytes - Viewed (0) -
docs/em/docs/tutorial/query-params-str-validations.md
{!> ../../../docs_src/query_params_str_validations/tutorial009_py310.py!} ``` ## π π’ π β‘οΈ π¬ π π« π π π’ π«π. π βοΈ π β«οΈ π€ βͺ β©οΈ π€ π©βπ» βοΈ β«οΈ, βοΈ π π π©Ί π― π¦ β«οΈ <abbr title="obsolete, recommended not to use it">π’</abbr>. β€΄οΈ πΆββοΈ π’ `deprecated=True` `Query`: === "π 3οΈβ£.6οΈβ£ & π" ```Python hl_lines="18" {!> ../../../docs_src/query_params_str_validations/tutorial010.py!} ```
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Mar 22 01:42:11 GMT 2024 - 11.9K bytes - Viewed (0)