Consider a json object:
{
“config”: {“key1”: “value”}
}
Within the html template (which is rendered using the above json as the context, how do access the “key1” directly? Conceptually I want to do the following:
<html>
<body>
The config value is {{config['key1']}}
</body>
</html>
but, obviously that does not work.
In other words how do I access any element of a dictionary object of the context within a template?
The issue (as pointed out by Tomasz Zielinski in a comment) that django supports dictionary objects directly – not json.