Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
unistUtilVisit(node, (n: any) => {
if (n.type === 'image') {
if (n.url) {
found = n.url;
return unistUtilVisit.EXIT;
}
}
});
return found;
visit(node, 'heading', (headingNode: any) => {
title = convertMdastToString(headingNode)
if (title.length > 0) {
return visit.EXIT
} else {
return visit.CONTINUE
}
})
if (title.length > 0) return title
function visitor(node) {
var depth
if (!generated(node)) {
if (node.type === 'heading') {
depth = node.depth
} else if (node.type === 'html') {
depth = infer(node)
}
if (depth !== undefined) {
if (depth !== style) {
file.message('First heading level should be `' + style + '`', node)
}
return visit.EXIT
}
}
}
}
function findLink() {
linkInFallbackContent = true
return visit.EXIT
}
}