DesignLiquido / xslt-processor

A JavaScript XSLT processor without native library dependencies
GNU Lesser General Public License v3.0
95 stars 30 forks source link

root template match can be anything besides just "/" #35

Closed berenddeboer closed 1 year ago

berenddeboer commented 4 years ago

See pull request #34 for more details. Just adds a failing test.

leonelsanchesdasilva commented 1 year ago

Hi @berenddeboer. Thanks for the test on this.

Using your test, I got to find that the evaluation context starts on a #document element, which is created above the first element for some reason. That's why this matches:

<xsl:template match="/">

But this does not:

<xsl:template match="/root">

My next version will have a fix for this, specifically.

leonelsanchesdasilva commented 1 year ago

Solved on https://github.com/DesignLiquido/xslt-processor/releases/tag/v1.0.0