from django.conf.urls import include, url

from django.views.generic import TemplateView

from votes.views import VoteView

urlpatterns = [
    url(r'^(?P<vote_name>[\w-]+)$', VoteView.as_view()),
]

from django.conf.urls import include, url

from django.views.generic import TemplateView

from votes.views import VoteView

urlpatterns = [
    url(r'^(?P<vote_name>[\w-]+)$', VoteView.as_view(), name="vote"),
]

Add name to vote view URL
Add name to vote view URL

  from django.conf.urls import include, url
  
  from django.views.generic import TemplateView
  
  from votes.views import VoteView
  
  urlpatterns = [
-     url(r'^(?P<vote_name>[\w-]+)$', VoteView.as_view()),
+     url(r'^(?P<vote_name>[\w-]+)$', VoteView.as_view(), name="vote"),
  ]
  
Add name to vote view URL
## Code Before:
from django.conf.urls import include, url

from django.views.generic import TemplateView

from votes.views import VoteView

urlpatterns = [
    url(r'^(?P<vote_name>[\w-]+)$', VoteView.as_view()),
]

## Instruction:
Add name to vote view URL
## Code After:
from django.conf.urls import include, url

from django.views.generic import TemplateView

from votes.views import VoteView

urlpatterns = [
    url(r'^(?P<vote_name>[\w-]+)$', VoteView.as_view(), name="vote"),
]
