Skip to content

kitware-resonant/django-ninja-cursor-pagination

Repository files navigation

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")

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages