Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion eslint.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ export default [
camelcase: 'off', // Many gh apis use underscores, 600+ uses

// Disabled rules to review
'@typescript-eslint/ban-ts-comment': 'off', // 50+
'github/array-foreach': 'off', // 250+
'no-console': 'off', // 800+
'@typescript-eslint/no-explicit-any': 'off', // 1000+
Expand Down
1 change: 0 additions & 1 deletion src/assets/scripts/validate-asset-images.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import path from 'path'
import { program } from 'commander'
import chalk from 'chalk'
import cheerio from 'cheerio'
// @ts-ignore see https://github.com/sindresorhus/file-type/issues/652
import { fileTypeFromFile } from 'file-type'
import walk from 'walk-sync'
import isSVG from 'is-svg'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/helpers/get-rules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { customConfig } from '@/content-linter/style/github-docs'
import type { Rule } from '@/content-linter/types'

// Import markdownlint rules - external library without TypeScript declarations
// @ts-ignore - markdownlint doesn't provide TypeScript declarations
import markdownlintRules from '../../../../node_modules/markdownlint/lib/rules'

export const customRules: Rule[] = gitHubDocsMarkdownlint.rules
Expand Down
5 changes: 4 additions & 1 deletion src/content-linter/lib/helpers/print-annotations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@
export function printAnnotationResults(
// Using 'any' type as results structure is dynamic and comes from various linting tools with different formats
results: any,
{ skippableRules = [], skippableFlawProperties = [] } = {},
{
skippableRules = [],
skippableFlawProperties = [],
}: { skippableRules?: string[]; skippableFlawProperties?: string[] } = {},
) {
for (const [file, flaws] of Object.entries(results)) {
// Using 'any' type for flaws as they have varying structures depending on the linting rule
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/helpers/utils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'
import matter from '@gr2m/gray-matter'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'

import type { RuleParams, RuleErrorCallback, MarkdownToken } from '@/content-linter/types'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/code-annotations.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '@/content-linter/lib/helpers/utils'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/ctas-schema.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import Ajv from 'ajv'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import yaml from 'js-yaml'

Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/expired-content.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, newLineRe } from 'markdownlint-rule-helpers'

import type { RuleParams, RuleErrorCallback, MarkdownToken, Rule } from '@/content-linter/types'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import fs from 'fs'
import path from 'path'
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import type { RuleParams, RuleErrorCallback } from '../../types'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import fs from 'fs'
import path from 'path'
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '../helpers/utils'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/frontmatter-schema.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import { intersection } from 'lodash-es'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import { getFrontmatter } from '@/content-linter/lib/helpers/utils'
import type { RuleParams, RuleErrorCallback, Rule } from '@/content-linter/types'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import path from 'path'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError, ellipsify } from 'markdownlint-rule-helpers'
import type { RuleParams, RuleErrorCallback } from '../../types'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError, ellipsify } from 'markdownlint-rule-helpers'
import type { RuleParams, RuleErrorCallback } from '../../types'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'

import type { RuleParams, RuleErrorCallback, MarkdownToken } from '@/content-linter/types'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { forEachInlineChild, getRange } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import type { RuleParams, RuleErrorCallback } from '../../types'

Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/image-no-gif.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { forEachInlineChild } from '@/content-linter/lib/helpers/utils'
Expand Down
2 changes: 0 additions & 2 deletions src/content-linter/lib/linting-rules/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// @ts-ignore - markdownlint-rule-search-replace doesn't provide TypeScript declarations
import searchReplace from 'markdownlint-rule-search-replace'
// @ts-ignore - @github/markdownlint-github doesn't provide TypeScript declarations
import markdownlintGitHub from '@github/markdownlint-github'

import { imageAltTextEndPunctuation } from '@/content-linter/lib/linting-rules/image-alt-text-end-punctuation'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { filterTokens } from 'markdownlint-rule-helpers'

import { addFixErrorDetail, getRange } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'

import { getRange } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { filterTokens } from 'markdownlint-rule-helpers'

import { addFixErrorDetail, getRange } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import fs from 'fs'
import path from 'path'
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '../helpers/utils'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/link-punctuation.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'
import type { RuleParams, RuleErrorCallback, Rule } from '../../types'

Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/link-quotation.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'
import { getRange, quotePrecedesLinkOpen } from '../helpers/utils'
import { escapeRegExp } from 'lodash-es'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/liquid-data-tags.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import { TokenKind } from 'liquidjs'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { TokenKind } from 'liquidjs'
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getLiquidTokens, conditionalTags, getPositionData } from '../helpers/liquid-utils'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/liquid-syntax.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getFrontmatter } from '../helpers/utils'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/liquid-versioning.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import semver from 'semver'
import { TokenKind } from 'liquidjs'
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import { getRange, addFixErrorDetail } from '../helpers/utils'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, ellipsify } from 'markdownlint-rule-helpers'

import { getRange } from '@/content-linter/lib/helpers/utils'
Expand Down
1 change: 0 additions & 1 deletion src/content-linter/lib/linting-rules/rai-reusable-usage.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import { TokenKind } from 'liquidjs'
import path from 'path'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'
import { getRange } from '../helpers/utils'
import frontmatter from '@/frame/lib/read-frontmatter'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError } from 'markdownlint-rule-helpers'

import type { RuleParams, RuleErrorCallback, Rule } from '@/content-linter/types'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'
import yaml from 'js-yaml'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// @ts-ignore - markdownlint-rule-helpers doesn't provide TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'

import type { RuleParams, RuleErrorCallback, MarkdownToken } from '@/content-linter/types'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import yaml from 'js-yaml'
// @ts-ignore - markdownlint-rule-helpers doesn't have TypeScript declarations
import { addError, filterTokens } from 'markdownlint-rule-helpers'

import { liquid } from '@/content-render/index'
Expand Down
Loading
Loading