Skip to main content

no-empty-see-tag

Disallow empty @see tags in TypeDoc comments.

Targeted pattern scopeโ€‹

This rule checks TypeDoc comments containing @see block tags.

What this rule reportsโ€‹

This rule reports @see tags that do not contain any meaningful reference โ€” no URL, no symbol, and no {@link} expression. Empty fenced code blocks are also treated as empty content.

Why this rule existsโ€‹

@see tags exist to guide readers toward related documentation, external resources, or related API symbols. An empty @see tag is a dangling pointer: it tells the reader to look somewhere, but provides no destination.

Empty or accidental @see entries often arise from incomplete edits or copy-paste issues. This rule flags them early so developers fill in the reference before shipping documentation.

โŒ Incorrectโ€‹

/**
* Normalize user-provided input.
* @see
*/
export function normalize(input: string): string {
return input.trim();
}

โœ… Correctโ€‹

/**
* Normalize user-provided input.
* @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/trim
*/
export function normalize(input: string): string {
return input.trim();
}
/**
* Widget component.
* @see {@link WidgetFactory} for the preferred construction pattern.
*/
export class Widget {}

Behavior and migration notesโ€‹

  • This rule checks only @see tags. It does not require you to use @see.
  • Empty fenced code blocks inside @see are treated as empty content.
  • This rule does not autofix because references must be authored intentionally.
  • To additionally enforce that @see content must be a URL or {@link} reference (not plain prose), pair this rule with typedoc/require-see-tag-link.

ESLint flat config exampleโ€‹

import typedocPlugin from "eslint-plugin-typedoc";

export default [
{
plugins: { typedoc: typedocPlugin },
rules: {
"typedoc/no-empty-see-tag": "error",
},
},
];

When not to use itโ€‹

Disable this rule only if your team explicitly uses empty @see tags as intentional placeholders during an active documentation workflow, removing them before publishing.

Package documentationโ€‹

TypeDoc package documentation:

Further readingโ€‹

Rule catalog ID: R029

Adoption resourcesโ€‹

  • Pair with typedoc/require-see-tag-link to enforce that @see tags contain an actual URL or {@link} reference, not just descriptive prose.