function isJSX(node) {
  return node && ['JSXElement', 'JSXFragment'].indexOf(node.type) >= 0;
}
Checks if a node represents a JSX element or fragment.
@param {object} node - node to check.
@returns {boolean} Whether or not the node if a JSX element or fragment.