r/javaScriptStudyGroup • u/hamletornot • Oct 02 '17
Why do we need to specify 'javascript' in html? Is there another script that is usable?
I figured maybe it's just implemented that way in case some other language does arrive. Though it seems like a tedious and bulky thing to do
2
Upvotes
2
u/Butch1022 Oct 09 '17
Its not required in html5. When you put <script> the html automatically assumes its JavaScript, but is considered good practice for writing clean code, especially as a beginner.
2
u/lphomiej Oct 02 '17
Actually, it's not required for html5.
https://www.w3.org/TR/html5/scripting-1.html#the-script-element