I appreciate their joke, but “HyperText Markup Language, the markup language” is a little redundant.
Some of us have had to include XSLT programming in our careers. We have seen into the dark abyss… and been paid to do it!
I appreciate their joke, but “HyperText Markup Language, the markup language” is a little redundant.
Some of us have had to include XSLT programming in our careers. We have seen into the dark abyss… and been paid to do it!
Well, except for the syntax and the lack of resources and that it wasn't designed to be a programming language...
Okay so it wasn't the best. But somewhere in there is a language which does want to be the best!
XSLT is a pattern matching DSL for converting trees into other trees. What things are trees? Programs.
It is also XML. XML is a boring business thing for boring business people associated with legacy Java codebases. We like json here. Or maybe yaml. To quote an otherwise excellent past colleague, "the pointy brackets hurt my eyes". It's horrible to edit in notepad too.
Who wants XML syntax for a purely functional programming language? No-one wants that, we write our compilers in C++ thank you.
As a bonus extra, "XML schema" are a similarly crufty rubbish old thing in nasty XML syntax that look suspiciously like "type of that tree". So you can typecheck the intermediate IR in your compiler pipeline. If you wrote it in the bad language from the before times. Emacs knows what those schema mean too.
The world has moved on to better marketed semantically worse things with prettier syntax. This brings me joy.
What XSLT did do was standardize XML on a transformation language. JSON never really got that, and the ecosystem is worse for it.
The definitive and complete resource is Michael Kay’s XSLT book (originally Wrox Press, but now part of O’Reilly I think?). Granted, a paper book as a resource isn’t great, but it’s some book!
Kay went to Cambridge (Trinity) and did his PhD under Sir Maurice Wilkes. He’s no joke: one of the examples from the book is implementing the Knight’s Tour. Although this is only the chapter pre-amble, the commentary is indicative of what kind of book this is:
https://www.oreilly.com/library/view/xslt-20-and/97804701927...
It’s like Dijkstra writing the definitive reference manual for CSS and one of the formatting examples being an engine for solving Towers of Hanoi.
While I have qualms about the utility of XSLT as a general purpose language — it’s fine if you embed it in an imperative language a la SQL in Python, and awful if you try and use it standalone — it also gave us XPath which is by far the best way of querying markup that I’ve ever used. (Well, until CSS got attribute selectors, so I use it less and less these days I suppose.)
(You probably know all this, but it was interesting to add to the thread.)
Is it pronounced "ex-slut"?