Fix iOS markdown image rendering
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
export interface MarkdownAstNodeWithChildren {
|
||||
type: string;
|
||||
children: MarkdownAstNodeWithChildren[];
|
||||
}
|
||||
|
||||
export function markdownNodeContainsType(node: MarkdownAstNodeWithChildren, type: string): boolean {
|
||||
if (node.type === type) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return node.children.some((child) => markdownNodeContainsType(child, type));
|
||||
}
|
||||
Reference in New Issue
Block a user