logoalt Hacker News

afavour • today at 3:25 AM • 3 replies • view on HN

Because JavaScript requires… a lot. A virtual machine, script parsing, etc. Making that a requirement before you even display any content on the page would be a regression.


Replies

dlcarrier • today at 3:36 AM

If CSS is Turing complete, that means it has a virtual machine with parsing and so forth. That means that difference between it and JavaScript is just syntax. (Same for any Turing complete language)

➕ show 1 reply
geocar • today at 4:47 AM

We had that. It was called XSLT.

Google said they weren't smart enough to implement it, or pay anyone to fix the one they forked a decade ago.

lioeters • today at 3:31 AM

I can see that, but CSS already requires a lot, no? Especially as they keep adding new features to it.

To me it feels like "programming in YAML", the way a declarative language/format acquires more and more features until you're writing functions in an awkward syntax that was never designed for it.

➕ show 2 replies