2 ms·
In my current codebase there is a lot more overriding going on than simply implementing the retrieve/list/etc... methods. On a quick review I found overrides fo
by pdhborges 3y ago
In my current codebase there is a lot more overriding going on than simply implementing the retrieve/list/etc... methods. On a quick review I found overrides for:
- get_object
- get_serializer_class
- perform_create
- get_queryset
- get_serializer_context
- perform_destroy
- rpep 3y agoIt depends on how much you want to rely on Mixins and using Serializer classes to do more than just serialise JSON. Neither of those are compulsory to use, and the more you lean into them the more inheritance you’re forced to do as soon as you need to customise the behaviour.