Skip to main content

Offline API docs for Litestar

Project description

litestar-offline-docs

This package enables "offline mode" for FastAPI (in other words lets you avoid loading assets from CDN).

Installation

poetry add litestar-offline-docs

Usage

Just construct static file handler and add it to Litestar application during initialization:

import litestar

from litestar_offline_docs import generate_static_files_config

app = litestar.Litestar(
    static_files_config=[generate_static_files_config()],
    ...
)

That's it. Now, the assets for API docs are served locally, not from CDN.

See also: fastapi-offline-docs.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

litestar_offline_docs-1.0.2.tar.gz (1.0 MB view details)

Uploaded Source

Built Distribution

litestar_offline_docs-1.0.2-py3-none-any.whl (1.1 MB view details)

Uploaded Python 3

File details

Details for the file litestar_offline_docs-1.0.2.tar.gz.

File metadata

  • Download URL: litestar_offline_docs-1.0.2.tar.gz
  • Upload date:
  • Size: 1.0 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.12.7 Linux/6.5.0-1025-azure

File hashes

Hashes for litestar_offline_docs-1.0.2.tar.gz
Algorithm Hash digest
SHA256 c72f86f18d41a3cbf3453942541ae760bc382c79cb77ab01931b1894b386993a
MD5 224ddda4a99bd129479b750dd6cd18e0
BLAKE2b-256 21a3c8cefd2484fb2784bc8fc2cd309053e2f903aa3917c6a03b18a2398cca0b

See more details on using hashes here.

File details

Details for the file litestar_offline_docs-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for litestar_offline_docs-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 cf029f51f01f306a84aedc21136bf70e7ec00d70579ec21e92ada8d186c0c493
MD5 46bbeaba11decc2a99a9ba07098598b2
BLAKE2b-256 191aef4042ac829075d403faacdc12d761ab89ddfa034fa8438eea27888534e8

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page