问题
Clicking on Hide on the Django debug toolbar (version 1.10.1) does not work on my Google Chrome (Version 69.0.3497.100). I'm using Django 1.11.15 and I can confirm that the Hide does indeed work on Firefox.
The following is output by the console:
Uncaught ReferenceError: djdt is not defined at toolbar.js:305
Line 305 being:
})(djdt.jQuery, djdt);
Anyone have suggestions on how to fix this or provide a possible workaround?
回答1:
The toolbar.js
file does not contain })(djdt.jQuery, djdt);
in version 1.10.1. It sounds like your browser may have cached an old version of toolbar.js
.
You may have to run collectstatic
To update your static files with the new version.
来源:https://stackoverflow.com/questions/52535869/django-debug-toolbar-wont-hide-on-chrome