Merge pull request #269665 from mjbvz/dev/mjbvz/delicious-sloth

Add lint rule for `as any` and bulk ignore all existing breaks
This commit is contained in:
Matt Bierner
2025-10-03 01:31:51 -07:00
committed by GitHub
484 changed files with 1217 additions and 2 deletions

View File

@@ -380,6 +380,7 @@ function addNamedHeaderRendering(md: InstanceType<typeof MarkdownIt>): void {
const originalRender = md.render;
md.render = function () {
slugCounter.clear();
// eslint-disable-next-line local/code-no-any-casts
return originalRender.apply(this, arguments as any);
};
}

View File

@@ -23,6 +23,7 @@ let documentResource = settings.settings.source;
const vscode = acquireVsCodeApi();
// eslint-disable-next-line local/code-no-any-casts
const originalState = vscode.getState() ?? {} as any;
const state = {
...originalState,
@@ -249,6 +250,7 @@ window.addEventListener('message', async event => {
}
newRoot.prepend(...styles);
// eslint-disable-next-line local/code-no-any-casts
morphdom(root, newRoot, {
childrenOnly: true,
onBeforeElUpdated: (fromEl: Element, toEl: Element) => {
@@ -439,6 +441,7 @@ function domEval(el: Element): void {
for (const key of preservedScriptAttributes) {
const val = node.getAttribute?.(key);
if (val) {
// eslint-disable-next-line local/code-no-any-casts
scriptTag.setAttribute(key, val as any);
}
}

View File

@@ -50,6 +50,7 @@ class AddToIgnoreLinksQuickFixProvider implements vscode.CodeActionProvider {
case DiagnosticCode.link_noSuchHeaderInOwnFile:
case DiagnosticCode.link_noSuchFile:
case DiagnosticCode.link_noSuchHeaderInFile: {
// eslint-disable-next-line local/code-no-any-casts
const hrefText = (diagnostic as any).data?.hrefText;
if (hrefText) {
const fix = new vscode.CodeAction(

View File

@@ -143,6 +143,7 @@ export class MarkdownItEngine implements IMdParser {
const frontMatterPlugin = await import('markdown-it-front-matter');
// Extract rules from front matter plugin and apply at a lower precedence
let fontMatterRule: any;
// eslint-disable-next-line local/code-no-any-casts
frontMatterPlugin.default(<any>{
block: {
ruler: {