mirror of
https://github.com/lemeow125/DRF_Template.git
synced 2025-09-18 05:29:37 +08:00
Move to uv/pyproject and overhaul project structure
This commit is contained in:
commit
fbb76f8196
26 changed files with 1981 additions and 0 deletions
22
src/api/urls.py
Normal file
22
src/api/urls.py
Normal file
|
@ -0,0 +1,22 @@
|
|||
from core.settings import config
|
||||
from django.contrib import admin
|
||||
from django.urls import include, path
|
||||
from drf_spectacular.views import (
|
||||
SpectacularAPIView,
|
||||
SpectacularRedocView,
|
||||
SpectacularSwaggerView,
|
||||
)
|
||||
|
||||
urlpatterns = [
|
||||
# path("accounts/", include("accounts.urls")),
|
||||
# Admin Panel
|
||||
path("admin/", admin.site.urls),
|
||||
# Swagger and Redoc API Doc URLs
|
||||
path("schema/", SpectacularAPIView.as_view(), name="schema"),
|
||||
path(
|
||||
"swagger/", SpectacularSwaggerView.as_view(url_name="schema"), name="swagger-ui"
|
||||
),
|
||||
path("redoc/", SpectacularRedocView.as_view(url_name="schema"), name="redoc"),
|
||||
# Silk Enabled on DEBUG
|
||||
*([path("silk/", include("silk.urls", namespace="silk"))] if config.DEBUG else []),
|
||||
]
|
Loading…
Add table
Add a link
Reference in a new issue