Warning: The type attribute is unnecessary for JavaScript resources.

By default WordPress adds scripts by using the type attribute enqueing styles and scripts, the latest html validators throw a warning because this is redundent/ unnecessary

Exmaple

Here is an example of the default way WordPress includes scripts

 

 

While this would be enough

 

 

Solution

 
The following script (add to your functions.php) removes the unnecessary attribute