Open adunning opened 2 years ago
Thanks @adunning for creating this issue.
@datho7561 already did some experimentation with Schematron, so it could give us some relevant feedback.
According @datho7561, Schematron requires Saxon for XSLT which grows the size of LemMinx uber JAR. We need to pay attention with this problem since vscode-xml is generaly used for XML, XSD, DTD.
We will see if RelaxNG is a lot used (by using telemetry, @rgrunber it should be nice to track that), and we will see if Schematron will become our priority.
Please vote for this issue if anybody are interested with Schematron.
It looks as if ph-schematron can operate without XSLT.
It looks as if ph-schematron can operate without XSLT.
Is it not a wrapper around to other Schematron implementation? We need to find time to investigate it.
There are several versions of ph-schematron, not all of which require Saxon. Its wiki explains the varying dependencies. Other Java implementations that do not appear to have other dependencies are https://github.com/itplr-kosit/validator and https://github.com/NASA-PDS/validate/.
There is also SaxonJS, which might be more lightweight than the full version. In this vein, there is an interesting implementation of Relax NG validation in TypeScript at https://github.com/mangalam-research/salve, used in the Scholarly XML extension for VS Code.
There is also SaxonJS, which might be more lightweight than the full version. In this vein, there is an interesting implementation of Relax NG validation in TypeScript at https://github.com/mangalam-research/salve, used in the Scholarly XML extension for VS Code.
@adunning we are in Java land because vscode-xml uses XML Language Server https://github.com/eclipse/lemminx so we cannot use TypeScript/JavaScript library.
The benefit with XML language server is that it can be consumed with other LSP client like Eclipse IDE, Sublime, etc which will benefit with RelaxNG support too and without having Java runtime because we provide binary to fix this problem.
+1 for this feature
With its Relax NG support (from #237), this language server is now extremely close to meeting the needs of a number of large XML initiatives such as DocBook, the Text Encoding Initiative, and Citation Style Language that largely expect users to edit XML files by hand, and being able to do this in everyday text editors would make an enormous difference. These rely on a combination of Relax NG and Schematron for validation. See the Schematron website for other examples.
Since LemMinX uses Jing for Relax NG, can its Schematron support be enabled easily? Jing only supports Schematron 1.5 rather than the finalized ISO Schematron, but according to their website support for ISO Schematron is coming.
For a list of validators covering ISO Schematron, see https://github.com/Schematron/awesome-schematron#software.
Thank you for all your work on this crucial piece of infrastructure!