3 ms·
> I quite like XML. Things like xpath make working with it XPath is great. 1.0 anyway, after that everything but the new functions was nonsense. But do note:
by masklinn 3y ago
> I quite like XML. Things like xpath make working with it
XPath is great. 1.0 anyway, after that everything but the new functions was nonsense.
But do note: XPath is not an xml dialect, it’s a non-XML DSL being applied to documents.
- account-5 3y agoThat makes sense about xpath not being an XML dialect. Its much easier than .NextSibling.ParentNode... etc etc. I always try to go for the path of least resistant.
- masklinn 3y ago> That makes sense about xpath not being an XML dialect. But the point is that it follows TFA's advice: while it's a DSL for working with XML, it's not an XML language. Wish that XSLT had been the same, it could have been so much better. > Its much easier than .NextSibling.ParentNode... etc etc. I don't think that has any relation. Also it does look a lot like what you wrote: ./following-sibling::*[position()=1]/parent::* even if you use the various shortcuts, since there is none for the next sibling or following siblings: ./following-sibling::*[1]/..