JSONEditor library not loaded in form assets
Closed this issue ยท 6 comments
bendavis78 commented
- django-json-widget version: master
- Django version: 2.2.12
- Python version: 3.x
When using the JSONEditor widget on a basic modelform (non-admin page), the JSONEditor library is not loaded, resulting in the following javascript error:
Uncaught ReferenceError: JSONEditor is not defined
AnderUstarroz commented
yes, same problem here, current version seems to be broken.
AnderUstarroz commented
Actually.. seems like it could be fixed just by adding this within your Django settings.py:
JSON_EDITOR_CSS = 'dist/jsoneditor.min.css'
JSON_EDITOR_JS = 'dist/jsoneditor.min.js'
kevindice commented
StevenMapes commented
Yeah this is fixed in v1.1.1 - https://github.com/jmrivas86/django-json-widget/releases/tag/v1.1.1
kevindice commented
Thanks!
jmrivas86 commented
Fixed in version 1.1.1 by @StevenMapes ๐ in #52