38👍
I believe your browser is caching your js
you could power refresh your browser, or clear browser cache?
on chrome control+f5 or shift + f5
i believe on firefox it is control + shift + r
16👍
Since you are editing JavaScript files and watching for the changes in the browser I assume you are actively developing your Django app and probably using Django’s development runserver. There is a better solution than clearing the browser cache and refreshing. If you run a watcher utility that supports the livereload protocol then your browser will automatically refresh whenever you change any static file.
The django-livereload-server
Python package provides a spiffy solution. Install it:
$ pip install django-livereload-server
Add 'livereload.middleware.LiveReloadScript'
to MIDDLEWARE_CLASSES
in settings.py.
Then run
$ ./manage.py livereload
before starting the runserver.
More documentation can be found at the django-livereload-server github site
- [Django]-Django – iterate number in for loop of a template
- [Django]-Django ignoring DEBUG value when I use os.environ, why?
- [Django]-'RelatedManager' object is not iterable Django
1👍
For me, opening Incognito Mode in Chrome let the browser show the recent changes in my .js
static files.
- [Django]-Best practices for storing references to AWS S3 objects in a database?
- [Django]-Django object multiple exclude()
- [Django]-How to POST a django form with AJAX & jQuery
0👍
To anyone who is using Firefox:
If you don’t want to clean your browser cache or it doesn’t solve your issue, you can try doing a hard refresh (hold Shift and press the refresh button).
- [Django]-How to make Django template raise an error if a variable is missing in context
- [Django]-How to get the common name for a pytz timezone eg. EST/EDT for America/New_York
- [Django]-Can to_representation() in Django Rest Framework access the normal fields