prevElementHasIf(node) {
    const prev = this.prevSibling(node)
    return (
      prev != null &&
      prev.startTag.attributes.some(
        (a) =>
          a.directive &&
          (a.key.name.name === 'if' || a.key.name.name === 'else-if')
      )
    )
  }
Check whether the previous sibling element has `if` or `else-if` directive.
@param {VElement} node The element node to check.
@returns {boolean} `true` if the previous sibling element has `if` or `else-if` directive.