Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function compile(markdown, options) {
const tableData = transformTableData(markdown)
return marksy({
createElement,
elements: {
code({ language, code }) {
let children = babel.transform(code, {
plugins: ['@babel/plugin-transform-react-jsx'],
}).code
children = children.replace(/(?<=createElement\().*?(?=, )/g, match => {
return `'${match}'`
})
return createElement(
'CodeHighlighter',
{
source: encodeProp(code),
language: language || 'javascript',
const React = require('react')
const path = require('path')
const marksy = require('marksy').marksy
const {readFile, fileExistsSync} = require('./utils')
const config = require('../config.json')
const compile = marksy({
components: {
Youtube (props) {
return (
<div style="{{textAlign:">
</div>