That's not necessarily "wrong", it's just not needed anymore. We used to have to include such comment tags so that browsers that don't understand script tags wouldn't output the code in the browser. Since virtually all browsers support the script tag, this is not needed anymore (same goes with CDATA for XHTML), but can still be visible in legacy code.
Is this a reply to my post? I'm not sure how does building your html programmatically relate to having HTML comments inside <script>. Could you explain what you mean?
why is that bad? is it because we can't guarantee those particular calls will synchronously execute, in relation to other possible calls going on in that page?
You want to avoid inline code as it is less maintainable – you want to have your code in one place, where it is expected to be, not attached to DOM elements in your markup, dotted all over the place.
Regarding monospaced fonts. I recently switched (back) to Anonymous Pro but I am not loving it. In Sublime like 1 pixels worth is cut off of the left side of some characters.
I need something better. What is everyone else using?
55
u/METALz Mar 01 '16 edited Mar 01 '16
There are so many things wrong with this picture that it could be easily posted to /r/programmerhumor