Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 13 for from (0.18 sec)

  1. docs/ko/docs/tutorial/middleware.md

    !!! note "기술적 세부사항"
        `from starlette.requests import request`를 사용할 수도 있습니다.
    
        **FastAPI**는 개발자에게 편의를 위해 이를 제공합니다. 그러나 Starlette에서 직접 파생되었습니다.
    
    ### `response`의 전과 후
    
    *경로 작동*을 받기 전 `request`와 함께 작동할 수 있는 코드를 추가할 수 있습니다.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Wed Jan 31 14:35:27 GMT 2024
    - 3.4K bytes
    - Viewed (0)
  2. docs/de/docs/reference/middleware.md

    Kann von `fastapi` importiert werden:
    
    ```python
    from fastapi.middleware.cors import CORSMiddleware
    ```
    
    ::: fastapi.middleware.gzip.GZipMiddleware
    
    Kann von `fastapi` importiert werden:
    
    ```python
    from fastapi.middleware.gzip import GZipMiddleware
    ```
    
    ::: fastapi.middleware.httpsredirect.HTTPSRedirectMiddleware
    
    Kann von `fastapi` importiert werden:
    
    ```python
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 30 18:15:39 GMT 2024
    - 1001 bytes
    - Viewed (0)
  3. docs/en/docs/reference/middleware.md

    It can be imported from `fastapi`:
    
    ```python
    from fastapi.middleware.cors import CORSMiddleware
    ```
    
    ::: fastapi.middleware.gzip.GZipMiddleware
    
    It can be imported from `fastapi`:
    
    ```python
    from fastapi.middleware.gzip import GZipMiddleware
    ```
    
    ::: fastapi.middleware.httpsredirect.HTTPSRedirectMiddleware
    
    It can be imported from `fastapi`:
    
    ```python
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:53:19 GMT 2024
    - 991 bytes
    - Viewed (0)
  4. docs/fa/docs/tutorial/middleware.md

    !!! توجه "جزئیات فنی"
        شما همچنین می‌توانید از `from starlette.requests import Request` استفاده کنید.
    
        **FastAPI** این را به عنوان یک سهولت برای شما به عنوان برنامه‌نویس فراهم می‌کند. اما این مستقیما از Starlette به دست می‌آید.
    
    ### قبل و بعد از `پاسخ`
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Mon Jan 29 17:53:46 GMT 2024
    - 4.4K bytes
    - Viewed (0)
  5. docs/zh/docs/advanced/middleware.md

    因此,有些第三方 ASGI 中间件的文档推荐以如下方式使用中间件:
    
    ```Python
    from unicorn import UnicornMiddleware
    
    app = SomeASGIApp()
    
    new_app = UnicornMiddleware(app, some_config="rainbow")
    ```
    
    但 FastAPI(实际上是 Starlette)提供了一种更简单的方式,能让内部中间件在处理服务器错误的同时,还能让自定义异常处理器正常运作。
    
    为此,要使用 `app.add_middleware()` (与 CORS 中的示例一样)。
    
    ```Python
    from fastapi import FastAPI
    from unicorn import UnicornMiddleware
    
    app = FastAPI()
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 30 22:44:27 GMT 2024
    - 3.6K bytes
    - Viewed (0)
  6. docs/de/docs/advanced/middleware.md

    Dazu verwenden Sie `app.add_middleware()` (wie schon im Beispiel für CORS gesehen).
    
    ```Python
    from fastapi import FastAPI
    from unicorn import UnicornMiddleware
    
    app = FastAPI()
    
    app.add_middleware(UnicornMiddleware, some_config="rainbow")
    ```
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 30 20:18:15 GMT 2024
    - 4.4K bytes
    - Viewed (0)
  7. docs/em/docs/advanced/middleware.md

    , 🧾 🥉-🥳 🔫 🛠️ 👫 🔜 🎲 💬 👆 🕳 💖:
    
    ```Python
    from unicorn import UnicornMiddleware
    
    app = SomeASGIApp()
    
    new_app = UnicornMiddleware(app, some_config="rainbow")
    ```
    
    ✋️ FastAPI (🤙 💃) 🚚 🙅 🌌 ⚫️ 👈 ⚒ 💭 👈 🔗 🛠️ 🍵 💽 ❌ & 🛃 ⚠ 🐕‍🦺 👷 ☑.
    
    👈, 👆 ⚙️ `app.add_middleware()` (🖼 ⚜).
    
    ```Python
    from fastapi import FastAPI
    from unicorn import UnicornMiddleware
    
    app = FastAPI()
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Apr 01 09:26:04 GMT 2023
    - 3.3K bytes
    - Viewed (0)
  8. docs/em/docs/tutorial/middleware.md

    !!! note "📡 ℹ"
        👆 💪 ⚙️ `from starlette.requests import Request`.
    
        **FastAPI** 🚚 ⚫️ 🏪 👆, 👩‍💻. ✋️ ⚫️ 👟 🔗 ⚪️➡️ 💃.
    
    ### ⏭ & ⏮️ `response`
    
    👆 💪 🚮 📟 🏃 ⏮️ `request`, ⏭ 🙆 *➡ 🛠️* 📨 ⚫️.
    
    & ⏮️ `response` 🏗, ⏭ 🛬 ⚫️.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Apr 01 09:26:04 GMT 2023
    - 2.4K bytes
    - Viewed (0)
  9. docs/en/docs/advanced/middleware.md

    For that, you use `app.add_middleware()` (as in the example for CORS).
    
    ```Python
    from fastapi import FastAPI
    from unicorn import UnicornMiddleware
    
    app = FastAPI()
    
    app.add_middleware(UnicornMiddleware, some_config="rainbow")
    ```
    
    `app.add_middleware()` receives a middleware class as the first argument and any additional arguments to be passed to the middleware.
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Mar 10 18:27:10 GMT 2023
    - 4K bytes
    - Viewed (0)
  10. docs/en/docs/tutorial/middleware.md

    !!! note "Technical Details"
        You could also use `from starlette.requests import Request`.
    
        **FastAPI** provides it as a convenience for you, the developer. But it comes directly from Starlette.
    
    ### Before and after the `response`
    
    You can add code to be run with the `request`,  before any *path operation* receives it.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Jan 11 16:31:18 GMT 2024
    - 2.9K bytes
    - Viewed (0)
Back to top