Does React really violate Separation of Concern by putting HTML and JS in a single file?View other answers to this thread
3.4K+ developers have started their personal blogs on Hashnode in the last one month.
Write in Markdown · Publish articles on custom domain · Gain readership on day zero · Automatic GitHub backup and more
In simple apps this might not seem like a big deal, especially when starting out.
You are for all intents and purposes very close to writing client side PHP. Or Perl, both of which allow you to mix and mingle.
As your projects get bigger, you hopefully are using modules and life is still pretty perky. But at some point the person who has to deal with the html fragment will need to be someone proficient only with HTML, and they won't know what they are looking at. Or worse, you will find out that you now own a very crazy mixture of HTML and CSS written by someone who went a little off the deep end mingling.