Created
January 24, 2013 15:26
-
-
Save ludder/4623036 to your computer and use it in GitHub Desktop.
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
/* | |
Returns true if element has next sibling (of type element) | |
*/ | |
function hasNextSibling(node) { | |
var bln = false; | |
while( (node = node.nextSibling) !== null ) { | |
if (node.nodeType !== 1) { | |
continue; | |
} | |
bln = true; | |
} | |
return bln; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment