xsl:template/@priority

In 4.0 would it be a good idea to allow xsl:template/@priority to be
constructable based on, say, static parameters?

The motivation here are cases where I have wanted to adjust via parameters
how template priorities are weighted. One could argue that @use-when is
always available. But @priority is bound to gradated criteria, not merely
true or false.

An example use case:

<xsl:param name="priority-weight" as="xs:integer" select="-1" static="yes"
/>
<xsl:template ... priority = "{1 * $priority-weight}"/>


Authors then could specify rather nuance conditions for priorities.

I think this would be chaos if exposed to dynamic values. But static ones?

Again, just an idea.

jk
-- 
Joel Kalvesmaki
kalvesmaki.com

Received on Tuesday, 1 December 2020 15:03:23 UTC