Skip to content

Instantly share code, notes, and snippets.

@aliceridgway
Created June 25, 2022 20:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aliceridgway/bd6841bf37c3ecf38396d3b144609384 to your computer and use it in GitHub Desktop.
Save aliceridgway/bd6841bf37c3ecf38396d3b144609384 to your computer and use it in GitHub Desktop.
from django.urls import path
from . import views
urlpatterns = [
path("", views.index, name="index"),
path("add", views.add_post, name="add_post"),
path("<slug:slug>", views.post_detail, name="post_detail"),
path("<slug:slug>/publish", views.publish, name="publish"),
path("<slug:slug>/edit", views.edit_post, name="edit"),
path("<slug:slug>/delete", views.delete_post, name="delete"),
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment