Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 61 - 70 of 914 for Tip (0.07 seconds)

  1. docs/en/docs/how-to/index.md

    If something seems interesting and useful to your project, go ahead and check it, but otherwise, you might probably just skip them.
    
    /// tip
    
    If you want to **learn FastAPI** in a structured way (recommended), go and read the [Tutorial - User Guide](../tutorial/index.md) chapter by chapter instead.
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 05 18:13:19 GMT 2026
    - 582 bytes
    - Click Count (0)
  2. docs/zh-hant/docs/tutorial/security/simple-oauth2.md

    而且它還應該有一個 `access_token`,其值為包含我們存取權杖的字串。
    
    在這個簡單示例中,我們會不安全地直接回傳相同的 `username` 當作 token。
    
    /// tip
    
    下一章你會看到真正安全的實作,包含密碼雜湊與 <abbr title="JSON Web Tokens - JSON 網頁權杖">JWT</abbr> tokens。
    
    但現在先把注意力放在我們需要的這些細節上。
    
    ///
    
    {* ../../docs_src/security/tutorial003_an_py310.py hl[87] *}
    
    /// tip
    
    依照規範,你應該回傳一個包含 `access_token` 與 `token_type` 的 JSON,就像這個範例。
    
    這部分需要你自己在程式中完成,並確保使用這些 JSON key。
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:05:38 GMT 2026
    - 9.1K bytes
    - Click Count (0)
  3. docs/en/docs/advanced/websockets.md

    ```
    
    </div>
    
    Open your browser at [http://127.0.0.1:8000](http://127.0.0.1:8000).
    
    There you can set:
    
    * The "Item ID", used in the path.
    * The "Token" used as a query parameter.
    
    /// tip
    
    Notice that the query `token` will be handled by a dependency.
    
    ///
    
    With that you can connect the WebSocket and then send and receive messages:
    
    <img src="/img/tutorial/websockets/image05.png">
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Sat Mar 07 09:29:03 GMT 2026
    - 5.3K bytes
    - Click Count (0)
  4. docs/zh/docs/tutorial/sql-databases.md

    这里,我们来看一个使用 [SQLModel](https://sqlmodel.tiangolo.com/) 的示例。
    
    **SQLModel** 基于 [SQLAlchemy](https://www.sqlalchemy.org/) 和 Pydantic 构建。它由 **FastAPI** 的同一作者制作,旨在完美匹配需要使用**SQL 数据库**的 FastAPI 应用程序。
    
    /// tip | 提示
    
    你可以使用任意其他你想要的 SQL 或 NoSQL 数据库库(在某些情况下称为 <abbr title="Object Relational Mapper - 对象关系映射器: 一个术语,用来指代一种库,其中某些类表示 SQL 表,这些类的实例表示这些表中的行">"ORMs"</abbr>),FastAPI 不会强迫你使用任何东西。😎
    
    ///
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 15.4K bytes
    - Click Count (0)
  5. docs/zh-hant/docs/how-to/authentication-error-status-code.md

    例如,你可以建立 `HTTPBearer` 的子類別,讓它回傳 `403 Forbidden` 錯誤,而不是預設的 `401 Unauthorized` 錯誤:
    
    {* ../../docs_src/authentication_error_status_code/tutorial001_an_py310.py hl[9:13] *}
    
    /// tip
    注意這個函式回傳的是例外物件本身,而不是直接拋出它。拋出的動作會在其餘的內部程式碼中處理。
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:05:38 GMT 2026
    - 1.1K bytes
    - Click Count (0)
  6. docs/en/docs/environment-variables.md

    # Environment Variables { #environment-variables }
    
    /// tip
    
    If you already know what "environment variables" are and how to use them, feel free to skip this.
    
    ///
    
    An environment variable (also known as "**env var**") is a variable that lives **outside** of the Python code, in the **operating system**, and could be read by your Python code (or by other programs as well).
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 05 18:13:19 GMT 2026
    - 7.9K bytes
    - Click Count (0)
  7. docs/zh/docs/tutorial/dependencies/dependencies-with-yield.md

    # 使用 yield 的依赖项 { #dependencies-with-yield }
    
    FastAPI 支持那些在完成后执行一些<dfn title="有时也称为:“退出代码”、“清理代码”、“拆卸代码”、“关闭代码”、“上下文管理器退出代码”等">额外步骤</dfn>的依赖项。
    
    为此,使用 `yield` 而不是 `return`,并把这些额外步骤(代码)写在后面。
    
    /// tip | 提示
    
    确保在每个依赖里只使用一次 `yield`。
    
    ///
    
    /// note | 技术细节
    
    任何可以与以下装饰器一起使用的函数:
    
    * [`@contextlib.contextmanager`](https://docs.python.org/3/library/contextlib.html#contextlib.contextmanager) 或
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 12.1K bytes
    - Click Count (0)
  8. docs/uk/llm-prompt.md

    - wildcard: дика карта
    
    ### `///` admonitions
    
    - Keep the admonition keyword in English (do not translate `note`, `tip`, etc.).
    - If a title is present, prefer these canonical titles (choose one canonical form where variants exist):
    
    - `/// note | Примітка`
    - `/// note | Технічні деталі`
    - `/// tip | Порада`
    - `/// warning | Попередження`
    - `/// info | Інформація`
    - `/// danger | Обережно`
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Wed Feb 04 16:47:51 GMT 2026
    - 4K bytes
    - Click Count (0)
  9. docs/zh/docs/tutorial/security/simple-oauth2.md

    返回内容还应包含 `access_token` 字段,它是包含权限 Token 的字符串。
    
    本例只是简单的演示,返回的 Token 就是 `username`,但这种方式极不安全。
    
    /// tip | 提示
    
    下一章介绍使用哈希密码和 <abbr title="JSON Web Tokens - JSON Web 令牌">JWT</abbr> Token 的真正安全机制。
    
    但现在,仅关注所需的特定细节。
    
    ///
    
    {* ../../docs_src/security/tutorial003_an_py310.py hl[87] *}
    
    /// tip | 提示
    
    按规范的要求,应像本示例一样,返回带有 `access_token` 和 `token_type` 的 JSON 对象。
    
    这是开发者必须在代码中自行完成的工作,并且要确保使用这些 JSON 的键。
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 9K bytes
    - Click Count (0)
  10. docs/ko/docs/tutorial/path-params.md

    `str`을 상속함으로써 API 문서는 값이 `string` 형이어야 하는 것을 알게 되고 이는 문서에 제대로 표시됩니다.
    
    가능한 값들에 해당하는 고정된 값의 클래스 어트리뷰트들을 만듭니다:
    
    {* ../../docs_src/path_params/tutorial005_py310.py hl[1,6:9] *}
    
    /// tip | 팁
    
    혹시 궁금하다면, "AlexNet", "ResNet", 그리고 "LeNet"은 그저 머신 러닝 <dfn title="기술적으로는 딥 러닝 모델 아키텍처">모델</dfn>들의 이름입니다.
    
    ///
    
    ### *경로 매개변수* 선언 { #declare-a-path-parameter }
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 14:06:26 GMT 2026
    - 9.9K bytes
    - Click Count (0)
Back to Top