Can someone give an example when xsl: foreach is really useful?
I just made a project and came to the conclusion that everywhere I can replace it with an appropriate one <xsl:apply-templates />. <xsl:if>and <xsl:when/>sometimes make the code shorter, and I cannot effectively replace it <apply-templates/>in a functional style.
Is it <xsl:foreach>recognized harmful in any way?
Well, thanks to everyone, I really could not choose the answer among the best. I think it would be better to collect different cases.
Sorry for someone who denies the answers - it's not me :)
source
share