MCPcopy Create free account
hub / github.com/benoitpointet/jquery-scrollsnap-plugin / assert

Function assert

demo/foundation/javascripts/jquery.js:3801–3812  ·  view source on GitHub ↗
( fn )

Source from the content-addressed store, hash-verified

3799
3800 // Used for testing something on an element
3801 assert = function( fn ) {
3802 var div = document.createElement("div");
3803
3804 try {
3805 return fn( div );
3806 } catch (e) {
3807 return false;
3808 } finally {
3809 // release memory in IE
3810 div = null;
3811 }
3812 },
3813
3814 // Check if getElementsByTagName("*") returns only elements
3815 assertTagNameNoComments = assert(function( div ) {

Callers 1

jquery.jsFile · 0.85

Calls 1

fnFunction · 0.85

Tested by

no test coverage detected