- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for Vendor (0.18 sec)
-
scripts/docs.py
{% for sponsor in sponsors.gold -%} <a href="{{ sponsor.url }}" target="_blank" title="{{ sponsor.title }}"><img src="{{ sponsor.img }}"></a> {% endfor -%} {%- for sponsor in sponsors.silver -%} <a href="{{ sponsor.url }}" target="_blank" title="{{ sponsor.title }}"><img src="{{ sponsor.img }}"></a> {% endfor %} {% endif %} """ def generate_readme_content() -> str: en_index = en_docs_path / "docs" / "index.md"
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Mon Jan 22 19:26:14 GMT 2024 - 10.9K bytes - Viewed (1) -
docs_src/custom_response/tutorial009c.py
from typing import Any import orjson from fastapi import FastAPI, Response app = FastAPI() class CustomORJSONResponse(Response): media_type = "application/json" def render(self, content: Any) -> bytes: assert orjson is not None, "orjson must be installed" return orjson.dumps(content, option=orjson.OPT_INDENT_2) @app.get("/", response_class=CustomORJSONResponse) async def main():
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Thu Sep 01 09:32:30 GMT 2022 - 451 bytes - Viewed (0) -
fastapi/responses.py
Read more about it in the [FastAPI docs for Custom Response - HTML, Stream, File, others](https://fastapi.tiangolo.com/advanced/custom-response/). """ def render(self, content: Any) -> bytes: assert ujson is not None, "ujson must be installed to use UJSONResponse" return ujson.dumps(content, ensure_ascii=False).encode("utf-8") class ORJSONResponse(JSONResponse):
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Wed Oct 18 12:36:40 GMT 2023 - 1.7K bytes - Viewed (0) -
scripts/mkdocs_hooks.py
first_child.read_source(config=config) new_title = first_child.title or new_title # Creating a new section makes it render it collapsed by default # no idea why, so, let's just modify the existing one # new_section = Section(title=new_title, children=new_children) item.title = new_title
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Tue Oct 24 20:26:06 GMT 2023 - 5.1K bytes - Viewed (0) -
tests/test_default_response_class.py
from fastapi.responses import HTMLResponse, JSONResponse, PlainTextResponse from fastapi.testclient import TestClient class ORJSONResponse(JSONResponse): media_type = "application/x-orjson" def render(self, content: Any) -> bytes: return orjson.dumps(content) class OverrideResponse(JSONResponse): media_type = "application/x-override" app = FastAPI(default_response_class=ORJSONResponse)
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Sun Mar 01 20:49:20 GMT 2020 - 5.2K bytes - Viewed (0)