Why do the JS lessons require type="text/javascript"?


I've noticed that the JS lessons require users to add type="text/javascript" to script tags. Why does it do that? Literally every browser automatically assumes JavaScript in a script tag. Does it have something to do with the editor, maybe?

Just curious :slight_smile: Sorry if I'm using the forum wrong, I'm brand new here.


no, there are more options:
text/javascript, text/ecmascript, application/javascript, and application/ecmascript

but the latest html5 standards allow you to no longer specify a type attribute, in this case text/javascript (the most commonly used) is assumed, you can read about it here, scroll down to where type is explained