if I have a variable in the context of unknown length, for example; list=[{\'key\':\'A\'},{\'key\':\'B\'},{\'key\':\'C\'}]
list=[{\'key\':\'A\'},{\'key\':\'B\'},{\'key\':\'C\'}]
How can I get the last ob
Use this piece of code in your template:
{{ list|slice:":-1".items.0.0 }}