Metadata-Version: 2.1
Name: fastapi-offline-docs
Version: 1.0.0
Summary: Offline API docs for FastAPI
Author: community-of-python
Requires-Python: >=3.9,<4.0
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Dist: fastapi (>=0.101.1,<1.0.0)
Description-Content-Type: text/markdown

# fastapi-offline-docs

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

# Installation

```sh
poetry add fastapi-offline-docs
```

# Usage

Before:

```python
import fastapi

app = fastapi.FastAPI(docs_url="path/to/doc", redoc_url="path/to/redoc")
```

After:

```python
import fastapi
from fastapi_offline_docs import enable_offline_docs

app = fastapi.FastAPI(docs_url="path/to/doc", redoc_url="path/to/redoc")
enable_offline_docs(app)
```

Now, the assets for API docs are served locally, not from CDN.

See also: [litestar-offline-docs](https://github.com/community-of-python/litestar-offline-docs).

