|
|
|
|
|
by OceanKing
2673 days ago
|
|
Re: One Language Imagine writing a web app. Writing HTML and CSS inside your JS codebase seems like a terrible and inconvenient idea, especially combined with the “150 lines per file” thing. You’ll have a JS file which will basically contain just HTML and some logic to put it in the DOM (and by the separation of concerns principle, if the file was less than 150 lines you’d probably just end it there anyway) With a large web app, this would grow to hundreds of JS files. Some of these files would be by necessity named something like “page1-html.js” or something similar. At that point, you may as well call it “page1.html” and save yourself the headache. |
|