django-json-widget
django-json-widget copied to clipboard
allowSchemaSuggestions Not Working
- django-json-widget version:
- Django version: 3.2.20
- Python version: 3.8.10
- Operating System: Windows
Description
Hey, I was trying to use the allowSchemaSuggestions option from the jsoneditor package. Passed the argument as part of the options of the JSON editor widget, but when the page loads I get the warning:
Unknown option "allowSchemaSuggestions". This option will be ignored
What I Did
This is the configuration for my Widget
widgets = {
'configuration': JSONEditorWidget(
attrs={"style": "width: 100%; border: none; padding: unset;"},
options={
"allowSchemaSuggestions": True,
"schema": {
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "tag-configuration-schema",
"title": "Title",
"description": "Description",
"type": "object",
"additionalProperties": False,
"properties": {
"type": {
"type": "string",
"enum": ["access", "trunk"]
},
"vlan": {
"type": "number"
},
"isolationEnabled": {
"type": "boolean"
},
},
"required": []
}
}
),
}