In HTML5 <script> type is optional
MarcDiethelm opened this issue · 2 comments
MarcDiethelm commented
In HTML5 the type attribute is optional on the script tag, but required for HTML 4. It think it would be nice to not use the atttribute by default but rather have a configurable property, eg: useTypeAttribute (Boolean).
var js = pile.createJSManager({ useTypeAttribute: true }); // default: false
pocesar commented
since HTML5 was made to be mostly backward compatible, just an extra type="text/javascript"
won't change much. but currently there are other use cases for this, like angular templates that use type="text/ng-template"
, that might get along with this change
pocesar commented
implemented as scriptType
option on JS Manager, defaults to 'text/javascript'