Autoreload files in browser for Django developement with Linux
Install and run django-instant for the websockets
pip install django-autoreloader
Add to settings:
INSTANT_SUPERUSER_CHANNELS = [
["$autoreload"]
]
Add your watch list in settings.py:
# if not set the default is ["templates"]
ARWL = ["static/js", "static/css", "templates"]
# prevent paths from reloading: default is ["admin"]
ARX = ["admin", "do/not/reload"]
Run the Django dev server and launch the watcher in another terminal:
python3 manage.py autoreload