function getComment(html) {
	const commentStart = "<!--";
	const commentEnd = "-->";
	const regex = /^(eslint\b|global\s)/u;

	if (
		html.slice(0, commentStart.length) !== commentStart ||
		html.slice(-commentEnd.length) !== commentEnd
	) {
		return "";
	}

	const comment = html.slice(commentStart.length, -commentEnd.length);

	if (!regex.test(comment.trim())) {
		return "";
	}

	return comment;
}
Extracts `eslint-*` or `global` comments from HTML comments if present.
@param {string} html The text content of an HTML AST node.
@returns {string} The comment's text without the opening and closing tags or
    an empty string if the text is not an ESLint HTML comment.