1👍
✅
Refer to the following URL
set_vars_from_json_block
is a template tag
{ "menu":
[{"name":"About", "url":"{% url about %}"},
{"name":"People", "url":"{% url people %}"},
{"name":"Labs", "url":"{% url labs %}"},
{"name":"Blog", "url":"{% url blog %}"},
{"name":"Contact", "url":"{% url contact %}"}
]}
This loads the json snippet, and in the templatetag, it parses for end_set_vars_from_json_block
to make it a block based implementation.
You could just have one model to save all by specifying “type”. Check out Django Picklefield
Source:stackexchange.com