Skip to content

Instantly share code, notes, and snippets.

View juliaRobertav's full-sized avatar
🎯
Focusing

Julia Roberta juliaRobertav

🎯
Focusing
View GitHub Profile
@juliaRobertav
juliaRobertav / info.md
Created September 29, 2023 19:38 — forked from marteinn/info.md
Using the Fetch Api with Django Rest Framework

Using the Fetch Api with Django Rest Framework

Server

First, make sure you use the SessionAuthentication in Django. Put this in your settings.py

# Django rest framework
REST_FRAMEWORK = {
    'DEFAULT_AUTHENTICATION_CLASSES': [
 'rest_framework.authentication.SessionAuthentication'