A Django Ninja extension for cursor-based pagination.
Project description
django-ninja-cursor-pagination
This library adds a new pagination class for use with django-ninja which supports cursor-based pagination.
Installation
pip install django-ninja-cursor-pagination
Usage
from ninja.pagination import paginate
from ninja_cursor_pagination import CursorPagination
@router.get("/things", response=list[ThingSchema])
@paginate(CursorPagination)
def list_things(request):
return Thing.objects.order_by("title")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file django_ninja_cursor_pagination-0.1.0.tar.gz
.
File metadata
- Download URL: django_ninja_cursor_pagination-0.1.0.tar.gz
- Upload date:
- Size: 8.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dd0e67abc58db3f7638cdbeaf95d64780fe7eb8efd7bac8b0d03cdd2d3f9c91d |
|
MD5 | a402c94a388532fa708c6a13d89cdb9e |
|
BLAKE2b-256 | 5053a47b21deef6b755369d7fc483ee7d51c058de34eb7d0ac33005e27ffccce |
File details
Details for the file django_ninja_cursor_pagination-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: django_ninja_cursor_pagination-0.1.0-py3-none-any.whl
- Upload date:
- Size: 8.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1f35f55d419086f18c28e6bdc007c2c4b2f936354990dfabab8daf19da1d8b6c |
|
MD5 | 2b28dde63b043860db25779465a52d00 |
|
BLAKE2b-256 | d482e5175c26cd41e2db9093458bfdf3e191648da4843a825c95e1b66e9368e1 |