(blockType: string)
| 22 | * @returns true if the block should be treated as markdown |
| 23 | */ |
| 24 | export function isMarkdownBlockType(blockType: string): boolean { |
| 25 | // Input blocks (input-text, input-checkbox, etc.) are code |
| 26 | if (blockType.startsWith('input-')) { |
| 27 | return false |
| 28 | } |
| 29 | // Known code types |
| 30 | if ((CODE_BLOCK_TYPES as readonly string[]).includes(blockType)) { |
| 31 | return false |
| 32 | } |
| 33 | // Default to markdown for unknown types (less lossy) |
| 34 | return true |
| 35 | } |
| 36 | |
| 37 | /** |
| 38 | * Sorts object keys alphabetically while preserving the type. |
no outgoing calls
no test coverage detected