typedoc2md / typedoc-plugin-markdown

A plugin for TypeDoc that enables TypeScript API documentation to be generated in Markdown.
https://typedoc-plugin-markdown.org
MIT License
702 stars 176 forks source link

Escape issues with union types on propertiesFormat: "Table" #423

Closed adambergman closed 1 year ago

adambergman commented 1 year ago

When setting "propertiesFormat" to "Table", it appears that the pipes in union types are being escaped incorrectly and spaces are inserted between the \\ and | as if they were marking table columns. This was happening in next.8 and continues in next.9.

Block comment + TS Interface

/**
 * Options interface for `call` method
 */
export interface CallOptions {
  /**
   *  A component or string reference
   */
  component?: Component | string | null;
}

Generated markdown

#### Properties
| Property  | Modifiers  | Type        | Description                                       |
| :-------- | :--------- | :---------- | :------------------------------------------------ | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| component | `optional` | `null` \\   | `string` \\                                       | `Component` | A component or string reference |
tgreyuk commented 1 year ago

Thanks - this is super useful feedback. Will fix it now.

tgreyuk commented 1 year ago

This should be fixed in typedoc-plugin-markdown@4.0.0-next.10