Is there an easy way to turn off caching of static files in Django's development server?
我使用标准命令启动服务器:
$ python manage.py runserver
我已经将Django项目的/static
目录中的settings.py
个配置为提供静电文件.我还有一个中间件类,用于开发将Cache-Control
头设置为must-revalidate, no-cache
,但这似乎只影响不在我的/static
目录中的URL.