from django.conf.urls import url

from . import views

app_name = 'places'
urlpatterns = [
    url(r'^$', views.IndexView.as_view(), name='index'),
    url(r'^(?P<slug>[-\w]+)/$', views.PlaceView.as_view(), name='place'),
]

from django.urls import include, path

from . import views

app_name = 'places'
urlpatterns = [
    path('', views.IndexView.as_view(), name='index'),
    path('<slug:slug>/', views.PlaceView.as_view(), name='place'),
]

Move places urlpatterns to Django 2.0 preferred method
Move places urlpatterns to Django 2.0 preferred method
