[Answered ]-Serving static files in development with django-devserver


From the URL in @MarkLavin’s comment, I actually came across (rather, reminded of) the following:

# Add to end of urls.py
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
urlpatterns += staticfiles_urlpatterns()

That will allow the static files to be served and is ignored in production, so there doesn’t seem to be any side effects to the approach. However, it irks me a little to have to modify my urls.py just for this, but it’s probably only temporary until the noted pull request is merged.

If anyone has any other solutions, feel free to add them, though.

Leave a comment