2 ms·
For HTML 5 All you need is: <script> The type isn't necessary anymore. We know it's JS. See http://www.w3.org/TR/html5/scripting-1.html http://www.w3.org
by nailer 15y ago
For HTML 5 All you need is:
<script>
The type isn't necessary anymore. We know it's JS.
See http://www.w3.org/TR/html5/scripting-1.html http://www.w3.org/TR/html5/scripting-1.html
- ryanac 15y agoInteresting, just checked and this is the same for the style tag (no longer requires type), never knew that they have defaults now. :) http://www.w3.org/TR/html5/semantics.html#attr-style-type http://www.w3.org/TR/html5/semantics.html#attr-style-type
- bsimpson 15y agoUnless you're using <script> as a ghetto <template> node (e.g. handlebars) or for WebGL. But yeah, nobody cares if you write JS without @type.
- djacobs 15y agos/ghetto/standard/