Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for recommended (0.46 sec)

  1. 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)
  2. 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️⃣ &amp; πŸ”›"
    
        ```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)
Back to top