News for hackers. Stuff that matters.
Re:TinyJS – Shorten JavaScript QuerySelect with $ and $$ by franciscop on Wednesday October 02, 2024 @04:11PM (#41724562)
One big difference and why I've been experimenting with JSX[1] is that in that example, if the `text` comes from an untrusted source it can lead to XSS, which TinyJS prevents (I checked)!

[1] https://x.com/FPresencia/status/1838176000267452704

Re:TinyJS – Shorten JavaScript QuerySelect with $ and $$ by wruza on Wednesday October 02, 2024 @04:19PM (#41724630)
Even if it comes from a trusted source, you usually want a good distinction between html interpolation and just-text chunks.