Does anybody know of a way or a package that can recognize < and > when occuring in template contexts and automatically writes a > either right after the < or after the selected region when typing a <? (In other words, that behaves just as normal paren completion.)
I know that < and >are ambiguous if not evaluated in context and that this might therefore not be possible, that's why I am asking if anybody knows of a solution.
If however not all cases can be covered for technical reasons at least some would be possible, for example whenever < is typed right after template or when a block is selected that stands after template. And maybe some other cases.