DEV Community

Discussion on: Anyone else intolerant of html inside javascript? yes i mean React

Collapse
 
adam_cyclones profile image
Adam Crockett 🌀 • Edited

So I will repeat your point, you would rather markup with anything other than an XML derived language. Okay fair you would rather use another language which translates to html instead, by using pug in Vue, okay, let me offer another point of view, conceptually you dislike html but is is not 'real' html at all, under the hood it's a bunch of render functions, anything in JavaScript files is just JavaScript, and it's related to this: github.com/hyperhype/hyperscript/b... so both pug and "html" in js transform into that. Why don't you forego the overhead and just write that instead of compiling something that looks just like render functions?

Ultimately the web was born with html and it, just like CSS will always be compile targets because they are historically the base level of the web. And on the subject, name any other language other than html that if written incorrectly still parses, html is underrated.

The trouble is, the seperation of concerns opinion gets completely misunderstood, it doesn't say don't mix languages, it says don't mix responsibility, as Vue and react are for displaying html, html belongs here.

I must add that I am not arguing or ranting at all it's a valid opinion, but I wanted to give you some other perspectives.