Closed
Description
I have something like this in my markdown:
[](http://example.com/linkedpage.html)
Now I'm trying to have a switch in a custom renderer for link
type:
link: (node, children, parent, styles) => {
const firstChild = node.children || [{}]
if (firstChild.type === 'image') {
return <Touchable>...</Touchable>
} else {
return (
<Text
key={node.key}
style={styles.link}
onPress={() => console.log('OPEN LINK: ', node.attributes.href)}>
{children}
</Text>
)
}
},
But unfortunately all links are treated as inline text (see src/lib/util/getIsInlineTextType.js
which is why I think the children array is always empty for links.
Any plans on adding support for that as well?