Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.
import { map } from 'unist-util-map';
export default function rehypeExpressions(): any {
return function (node: any): any {
return map(node, (child) => {
if (child.type === 'mdxTextExpression') {
return { type: 'text', value: `{${(child as any).value}}` };
}
return child;
});
};