setting cors
This commit is contained in:
parent
2655518a86
commit
74ea8942cc
@ -145,11 +145,14 @@ STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles')
|
||||
|
||||
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
|
||||
|
||||
CORS_ALLOWED_ORIGINS = [
|
||||
"http://localhost:3000",
|
||||
"http://localhost:5173",
|
||||
"http://127.0.0.1:5173",
|
||||
]
|
||||
# CORS_ALLOWED_ORIGINS = [
|
||||
# "http://localhost:3000",
|
||||
# "http://localhost:5173",
|
||||
# "http://127.0.0.1:5173",
|
||||
# ]
|
||||
CORS_ALLOWED_ORIGINS = config(
|
||||
"CORS_ALLOWED_ORIGINS",
|
||||
default="http://localhost:3000,http://localhost:5173,http://127.0.0.1:5173", cast=Csv())
|
||||
|
||||
REST_FRAMEWORK = {
|
||||
'DEFAULT_PAGINATION_CLASS':
|
||||
|
||||
Loading…
Reference in New Issue
Block a user