Created
June 23, 2015 10:35
-
-
Save WebReflection/ba7d631bfd0fb5263e75 to your computer and use it in GitHub Desktop.
Inspired by jQuery, an inline function to solve forever any problem related to DOMContentLoaded (with or without defer)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!function(r,e,a,d,y){function $(f){d?f():r.push(f)}e.ready=$;e.addEventListener(a,y=function(){d=!e.removeEventListener(a,y,d);while(y=r.shift())y()},d)}([],document,'DOMContentLoaded',!1); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
for CSP