filter (callback) {
      const nodes = []

      this.traverse(function (node, path, parent) {
        if (callback(node, path, parent)) {
          nodes.push(node)
        }
      })

      return nodes
    }
Find any node in the node tree matching given filter function. For
example, to find all nodes of type SymbolNode having name 'x':

    const results = Node.filter(function (node) {
      return (node && node.isSymbolNode) && (node.name === 'x')
    })

@param {function(node: Node, path: string, parent: Node) : Node} callback
           A test function returning true when a node matches, and false
           otherwise. Function signature:
           callback(node: Node, index: string, parent: Node) : boolean
@return {Node[]} nodes
           An array with nodes matching given filter criteria