﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
34124	Developer experience on {% with %} template tag can be improved.	Oscar Cortez	nobody	"The ""with"" template tag just caches a complex variable under a simpler name, and from the Django Documentation we know that there's two ways to use this tag:

- normal form
{{{
{% with alpha=1 beta=2 %}
{% endwith %}
}}}

- verbose form
{{{
{% with business.employees.count as total %}
{% endwith %}
}}}

But recently I was reviewing some code and found this:

{{{
{% with first_post_image as post_images.first.image %}
...
{% endwith %}
}}}

As we can see the order of the parameters is wrong, I was a bit surprised that the Django template engine did not throw or raised an issue while trying to render the template, and in the same way I think the ticket #32157 is directly related to this. So I believe that we can improve the DX for this template tag and enforce the values that we want to cache, this means that we should allow only valid variable names and enforce value casting."	Cleanup/optimization	closed	Template system	4.1	Normal	wontfix	template tag	om.cortez.2010@…	Unreviewed	0	0	0	0	0	0
