CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-typedoc-plugin-markdown

A plugin for TypeDoc that enables TypeScript API documentation to be generated in Markdown.

Pending
Overview
Eval results
Files

configuration-options.mddocs/

Configuration Options

Comprehensive configuration system with extensive options for customizing markdown output, file organization, formatting, and behavior of the TypeDoc Plugin Markdown.

Capabilities

PluginOptions Interface

Complete interface defining all available plugin configuration options with their types and purposes.

/**
 * Describes the options declared by the plugin for customizing markdown output.
 * All configuration options available for the TypeDoc Plugin Markdown.
 */
interface PluginOptions {
  /** Custom anchor prefix to add to anchor links */
  anchorPrefix?: string;

  /** Specifies comment block tags that should preserve their position */
  blockTagsPreserveOrder?: string[];

  /** Sets the format of property groups for classes */
  classPropertiesFormat?: 'list' | 'table' | 'htmlTable';

  /** The format of custom anchors */
  customAnchorsFormat?: 'curlyBrace' | 'escapedCurlyBrace' | 'squareBracket';

  /** The file name of the entry page */
  entryFileName?: string;

  /** @deprecated This functionality has been deprecated in favour of the @mergeModuleWith tag */
  entryModule?: string;

  /** Sets the format of enumeration members */
  enumMembersFormat?: 'list' | 'table' | 'htmlTable';

  /** @deprecated This option has been renamed hideGroupHeadings to better reflect its purpose */
  excludeGroups?: boolean;

  /** Exclude writing @ scope directories in paths */
  excludeScopesInPaths?: boolean;

  /** Expand objects inside declarations */
  expandObjects?: boolean;

  /** Expand parameters in signature parentheses to display type information */
  expandParameters?: boolean;

  /** Specify the file extension for generated output files */
  fileExtension?: string;

  /** Flatten output files to a single directory */
  flattenOutputFiles?: boolean;

  /** Apply additional output formatting with Prettier */
  formatWithPrettier?: boolean;

  /** Do not print breadcrumbs */
  hideBreadcrumbs?: boolean;

  /** Excludes grouping by kind so all members are rendered at the same level */
  hideGroupHeadings?: boolean;

  /** Do not print page header */
  hidePageHeader?: boolean;

  /** Do not print page title */
  hidePageTitle?: boolean;

  /** Sets the format of index items */
  indexFormat?: 'list' | 'table' | 'htmlTable';

  /** Sets the format of property groups for interfaces */
  interfacePropertiesFormat?: 'list' | 'table' | 'htmlTable';

  /** Determines which members are exported to their own file */
  membersWithOwnFile?: (
    | 'Enum'
    | 'Variable'
    | 'Function'
    | 'Class'
    | 'Interface'
    | 'TypeAlias'
  )[];

  /** Appends the documentation index page to the readme page */
  mergeReadme?: boolean;

  /** The file name of the separate modules / index page */
  modulesFileName?: string;

  /** @deprecated This option has been deprecated in favour of TypeDoc `navigation` option */
  navigationModel?: {
    excludeGroups?: boolean;
    excludeCategories?: boolean;
    excludeFolders?: boolean;
  };

  /** @deprecated Deprecated in favour of `--router` */
  outputFileStrategy?: 'members' | 'modules';

  /** Configure page title output with placeholders */
  pageTitleTemplates?: {
    index?:
      | string
      | ((name: { projectName: string; version: string }) => string);
    member?:
      | string
      | ((name: {
          name: string;
          rawName: string;
          kind: string;
          isDeprecated: boolean;
          group?: string;
          codeKeyword?: string;
          keyword?: string;
        }) => string);
    module?:
      | string
      | ((name: {
          name: string;
          rawName: string;
          kind: string;
          isDeprecated: boolean;
        }) => string);
  };

  /** Sets the format of parameter and type parameter groups */
  parametersFormat?: 'list' | 'table' | 'htmlTable';

  /** Preserve anchor casing when generating link to symbols */
  preserveAnchorCasing?: boolean;

  /** Specify a custom Prettier configuration file location */
  prettierConfigFile?: string;

  /** @deprecated This option has been deprecated in favour of `--interfacePropertiesFormat` and `--classPropertiesFormat` */
  propertiesFormat?: 'list' | 'table' | 'htmlTable';

  /** Sets the format of style for property members for interfaces and classes */
  propertyMembersFormat?: 'list' | 'table' | 'htmlTable';

  /** Specify the base path for all urls */
  publicPath?: string;

  /** Sanitize HTML and JSX inside JsDoc comments */
  sanitizeComments?: boolean;

  /** Controls whether deprecated symbols have their page titles rendered with a strikethrough */
  strikeDeprecatedPageTitles?: boolean;

  /** Control how table columns are configured and displayed */
  tableColumnSettings?: {
    hideDefaults?: boolean;
    hideInherited?: boolean;
    hideModifiers?: boolean;
    hideOverrides?: boolean;
    hideSources?: boolean;
    hideValues?: boolean;
    leftAlignHeaders?: boolean;
  };

  /** @deprecated This option has been deprecated in favour of `--pageTitleTemplates` */
  textContentMappings?: Record<string, any>;

  /** Sets the format of style for type alias properties */
  typeAliasPropertiesFormat?: 'list' | 'table' | 'htmlTable';

  /** Sets the format of style for type declaration members */
  typeDeclarationFormat?: 'list' | 'table' | 'htmlTable';

  /** Set the visibility level for type declaration documentation */
  typeDeclarationVisibility?: 'compact' | 'verbose';

  /** Wraps signatures and declarations in code blocks */
  useCodeBlocks?: boolean;

  /** Add custom anchors like `{#custom-id}` to headings */
  useCustomAnchors?: boolean;

  /** Add HTML anchors to page headings */
  useHTMLAnchors?: boolean;

  /** Use HTML encoded entities for angle brackets */
  useHTMLEncodedBrackets?: boolean;
}

Configuration Categories

File Organization Options

Options controlling how documentation files are structured and named.

// File naming and organization
fileExtension?: string;        // Default: '.md'
entryFileName?: string;        // Default: 'README'  
modulesFileName?: string;      // Default: 'modules'
flattenOutputFiles?: boolean;  // Default: false
outputFileStrategy?: 'members' | 'modules'; // Default: 'modules' (deprecated)

// Members with individual files
membersWithOwnFile?: Array<'Enum' | 'Variable' | 'Function' | 'Class' | 'Interface' | 'TypeAlias'>;

Usage Example:

// TypeDoc configuration
{
  "plugin": ["typedoc-plugin-markdown"],
  "markdown": "./docs",
  "fileExtension": ".md",
  "entryFileName": "index",
  "flattenOutputFiles": false,
  "membersWithOwnFile": ["Class", "Interface", "Enum", "Function"]
}

Display and Formatting Options

Options controlling how content is displayed and formatted in the generated markdown.

// Page structure
hidePageHeader?: boolean;      // Default: false
hidePageTitle?: boolean;       // Default: false  
hideBreadcrumbs?: boolean;     // Default: false
hideGroupHeadings?: boolean;   // Default: false

// Content formatting
useCodeBlocks?: boolean;       // Default: false
useHTMLAnchors?: boolean;      // Default: false
useCustomAnchors?: boolean;    // Default: false
sanitizeComments?: boolean;    // Default: true
expandObjects?: boolean;       // Default: false
expandParameters?: boolean;    // Default: false

// Table formatting
indexFormat?: 'list' | 'table' | 'htmlTable';              // Default: 'list'
interfacePropertiesFormat?: 'list' | 'table' | 'htmlTable'; // Default: 'list'
classPropertiesFormat?: 'list' | 'table' | 'htmlTable';     // Default: 'list'
enumMembersFormat?: 'list' | 'table' | 'htmlTable';        // Default: 'list'
parametersFormat?: 'list' | 'table' | 'htmlTable';         // Default: 'list'
propertyMembersFormat?: 'list' | 'table' | 'htmlTable';    // Default: 'list'
typeAliasPropertiesFormat?: 'list' | 'table' | 'htmlTable'; // Default: 'list'
typeDeclarationFormat?: 'list' | 'table' | 'htmlTable';    // Default: 'list'

Usage Example:

// Enhanced table formatting configuration
{
  "useCodeBlocks": true,
  "useHTMLAnchors": true,
  "indexFormat": "table",
  "interfacePropertiesFormat": "htmlTable",
  "classPropertiesFormat": "table",
  "parametersFormat": "table",
  "tableColumnSettings": {
    "hideDefaults": false,
    "hideInherited": true,
    "leftAlignHeaders": true
  }
}

Table Column Configuration

Detailed control over table column visibility and formatting.

tableColumnSettings?: {
  /** Hide default values column */
  hideDefaults?: boolean;        // Default: false
  
  /** Hide inherited members column */
  hideInherited?: boolean;       // Default: false
  
  /** Hide modifiers column (public, private, etc.) */
  hideModifiers?: boolean;       // Default: false
  
  /** Hide overrides column */
  hideOverrides?: boolean;       // Default: false
  
  /** Hide sources column */
  hideSources?: boolean;         // Default: false
  
  /** Hide values column */
  hideValues?: boolean;          // Default: false
  
  /** Left-align table headers */
  leftAlignHeaders?: boolean;    // Default: false
};

Navigation and Linking Options

Options for controlling navigation and internal linking.

// Linking and anchors
anchorPrefix?: string;         // Default: ''
publicPath?: string;           // Default: ''
preserveAnchorCasing?: boolean; // Default: false
customAnchorsFormat?: 'curlyBrace' | 'escapedCurlyBrace' | 'squareBracket'; // Default: 'curlyBrace'

// Path handling
excludeScopesInPaths?: boolean; // Default: false

Page Title Customization

Templates for customizing page titles across different reflection types.

pageTitleTemplates?: {
  /** Template for index page title */
  index?: string | ((name: { projectName: string; version: string }) => string);
  
  /** Template for member page titles */
  member?: string | ((name: {
    name: string;
    rawName: string;
    kind: string;
    isDeprecated: boolean;
    group?: string;
    codeKeyword?: string;
    keyword?: string;
  }) => string);
  
  /** Template for module page titles */
  module?: string | ((name: {
    name: string;
    rawName: string;
    kind: string;
    isDeprecated: boolean;
  }) => string);
};

Usage Example:

{
  "pageTitleTemplates": {
    "index": "{projectName} v{version} Documentation",
    "member": "{kind}: {name}",
    "module": "Module: {name}"
  }
}

Advanced Configuration

Advanced options for specialized use cases and customization.

// Content processing
blockTagsPreserveOrder?: string[];   // Preserve order for these block tags

// Formatting with Prettier
formatWithPrettier?: boolean;        // Default: false
prettierConfigFile?: string;         // Path to Prettier config

// Deprecated options (included for backward compatibility)
excludeGroups?: boolean;            // @deprecated Use hideGroupHeadings
propertiesFormat?: 'list' | 'table' | 'htmlTable'; // @deprecated Use specific format options
textContentMappings?: Record<string, any>; // @deprecated Use pageTitleTemplates
entryModule?: string;               // @deprecated Use @mergeModuleWith tag
outputFileStrategy?: 'members' | 'modules'; // @deprecated Use --router
navigationModel?: {                 // @deprecated Use TypeDoc navigation option
  excludeGroups?: boolean;
  excludeCategories?: boolean;
  excludeFolders?: boolean;
};

Complete Configuration Example:

// typedoc.json - Comprehensive configuration
{
  "plugin": ["typedoc-plugin-markdown"],
  "markdown": "./docs",
  
  // File organization
  "fileExtension": ".md",
  "entryFileName": "index",
  "modulesFileName": "modules",
  "flattenOutputFiles": false,
  
  // Display options
  "hidePageHeader": false,
  "hidePageTitle": false,
  "hideBreadcrumbs": false,
  "useCodeBlocks": true,
  "useHTMLAnchors": true,
  
  // Table formatting
  "indexFormat": "table",
  "interfacePropertiesFormat": "htmlTable",
  "classPropertiesFormat": "table",
  "parametersFormat": "table",
  "tableColumnSettings": {
    "hideDefaults": false,
    "hideInherited": true,
    "leftAlignHeaders": true
  },
  
  // Page titles
  "pageTitleTemplates": {
    "index": "{projectName} Documentation",
    "member": "{kind}: {name}",
    "module": "Module: {name}"
  },
  
  // Content options
  "sanitizeComments": true,
  "expandObjects": false,
  "membersWithOwnFile": ["Class", "Interface", "Enum"],
  
  // Advanced options
  "formatWithPrettier": false,
  "useCustomAnchors": false,
  "preserveAnchorCasing": false
}

Install with Tessl CLI

npx tessl i tessl/npm-typedoc-plugin-markdown

docs

configuration-options.md

events-hooks.md

index.md

plugin-bootstrap.md

routing-system.md

theme-system.md

tile.json