remarkjs/remark-react

Code Snippets are not getting their class names?

kand617 opened this issue · 2 comments

Code Snippets seem to be loosing their language class names.
Nor is it passed to the props?
Does not work with the https://github.com/bebraw/remark-react-lowlight
I am invoking the library as follows:

    const item = remark().use(reactRenderer).processSync(this.props.md).contents;

The input for this.props.md is the following text:

  1. Autoload the SDK Package. This will include all the files and classes to your autoloader. Please note, If your downloaded our SDK using composer, replace PayPal-PHP-SDK with vendor. This applies for all sample code in our SDK.
<?php
// 1. Autoload the SDK Package. This will include all the files and classes to your autoloader
// Used for composer based installation
require __DIR__  . '/vendor/autoload.php';
// Use below for direct download installation
// require __DIR__  . '/PayPal-PHP-SDK/autoload.php';

Remark-react had nothing to do with it.

It could be that this is related to remark-react, check out the sanitize option.