hexojs / hexo-renderer-markdown-it

Markdown-it is a Markdown parser, done right. A faster and CommonMark compliant alternative for Hexo.
MIT License
340 stars 60 forks source link

codeblock mark not work #190

Open yanickxia opened 1 year ago

yanickxia commented 1 year ago

hexo default markdown-render support code mark. such like it.

  if (upgrade != nullptr) {
    const Router::RouteEntry::UpgradeMap* upgrade_map = filter_manager_callbacks_.upgradeMap();

    if (filter_chain_factory_.createUpgradeFilterChain(upgrade->value().getStringView(),
                                                       upgrade_map, *this)) {
      filter_manager_callbacks_.upgradeFilterChainCreated();
      return true;
    } else {
      upgrade_rejected = true;
      // Fall through to the default filter chain. The function calling this
      // will send a local reply indicating that the upgrade failed.
    }
  }
  //  create here !
  filter_chain_factory_.createFilterChain(*this);
  return !upgrade_rejected;
}

use codeblock it's works

{% codeblock lang:cpp createFilterChain https://github.com/envoyproxy/envoy/blob/b26b45eaacb810be390d7cfc7e21b8f5de32abfd/source/common/http/filter_manager.cc#L1444-L1459 github mark:1-2 %}