function checkNewlineBefore({
  string,
  globalIndex,
  startIndex,
  endIndex,
  node,
  result
}) {
  const symbol = string.substring(startIndex, endIndex + 1);
  let newLineBefore = false;

  let index = endIndex + 1;

  while (index && isWhitespace(string[index])) {
    if (string[index] === "\n") {
      newLineBefore = true;
      break;
    }

    index++;
  }

  if (newLineBefore) {
    const index = globalIndex + startIndex;
    utils.report({
      ruleName,
      result,
      node,
      message: messages.rejected(symbol),
      index,
      endIndex: index + symbol.length
    });
  }
}
The checker function: whether there is a newline before THAT operator.