- From: Michael Kay <mike@saxonica.com>
- Date: Tue, 1 Dec 2020 15:22:33 +0000
- To: Joel Kalvesmaki <kalvesmaki@gmail.com>
- Cc: public-xslt-40@w3.org
Received on Tuesday, 1 December 2020 15:22:48 UTC
You can do this in 3.0 with shadow attributes: _priority="{1 * $priority-weight}" Michael Kay Saxonica > On 1 Dec 2020, at 15:01, Joel Kalvesmaki <kalvesmaki@gmail.com> wrote: > > 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 <http://kalvesmaki.com/>
Received on Tuesday, 1 December 2020 15:22:48 UTC