DRF-polymorphic

Run CI Coverage status Code linting black Documentation Status

python-versions django-versions pypi-version

Polymorphic support for DRF without Django models

Overview

Polymorphism happens when a resource takes a certain shape depending on the type of the resource. Usually they have a common base type. The exact type/shape is not statically known, but depends on the run-time values.

Unlike django-rest-polymorphic this implementation doesn’t require the usage of django-polymorphic model classes and can be used even without django models.

The implementations also includes the extension for DRF spectacular schema generation.

Indices and tables