from rest_framework.decorators import api_view

@api_view(['GET', 'POST'])
def articles(request, format=None):
    data = {'articles': Article.objects.all()}
return Response(data, template_name='articles.html')
How to pass django rest framework response to html?