index.js
function findDeepestNode(node) {
	while (node.children.length) {
		node = node.children[node.children.length - 1];
	}

	return node;
}
function findDeepestNode(node) {
	while (node.children.length) {
		node = node.children[node.children.length - 1];
	}

	return node;
}
function findDeepestNode ( node ) { while ( node . children . length ) { node = node . children [ node . children . length - 1 ] ; } return node ; }
Finds node which is the deepest for in current node or node itself.
@param  {Node} node
@return {Node}
Finds node which is the deepest for in current node or node itself .