Remove outdated type annotations and lint suppressions.

This commit is contained in:
David Anson 2024-06-21 21:03:30 -07:00
parent d9c5d24e20
commit 1513e3803b
25 changed files with 208 additions and 322 deletions

View file

@ -32,11 +32,6 @@ module.exports = {
const htmlElements = params.config.html_elements;
const includeHtmlElements =
(htmlElements === undefined) ? true : !!htmlElements;
// eslint-disable-next-line jsdoc/valid-types
/** @type import("../helpers/micromark.cjs").Token[] */
const micromarkTokens =
// @ts-ignore
params.parsers.micromark.tokens;
const scannedTypes = new Set([ "data" ]);
if (includeCodeBlocks) {
scannedTypes.add("codeFlowValue");
@ -48,7 +43,7 @@ module.exports = {
}
const contentTokens =
filterByPredicate(
micromarkTokens,
params.parsers.micromark.tokens,
(token) => scannedTypes.has(token.type),
(token) => (
token.children.filter((t) => !ignoredChildTypes.has(t.type))
@ -96,8 +91,8 @@ module.exports = {
token.startLine,
name,
nameMatch,
null,
null,
undefined,
undefined,
[ column, length ],
{
"editColumn": column,