I need a classic controlpanel entry to store configs for my addon in the registry (created with plonecli) for Classic UI. Can someone share a recipe to create a JSONField for a control panel configlet? For example, TinyMCE control panel uses JSON to store some configs but uses a Schema.Text and a validator.
Is this the way to go? I see some references to a JSONField somewhere but it is not clear how to use it.
I'm testing JSONField with the schema. If you create a control panel configlet with plonecli, change from zope import schema to from plone import schema so you've some additional fields like JSONField.
If you don't put constraints in the schema, it always validate even if the json does not follow the schema. If the json is malformed, you get a traceback when saving (SyntaxError).
This is an example, if someone land in this page searching for info on JSONField: