Blog We love to talk!

Nov Tue

Cross Browser defer attribute

  •  11-10-2015

The boolean defer attribute on script elements allows the external JavaScript file to run when the DOM is loaded, without delaying page load first.

Browser Support

defer attribute is already supported by all major browser so it should be really easy to get it working cross browser.

Code Example

You can use defer attribute like this:

<script defer src="somefile.js"></script>

More Information

More information can be found here.

No Comments

Leave a Reply

Your email address will not be published.