我在用jekyll/gh页面。Maruku和RDiscount都与以下代码非常混淆:
<figure>
<a id="fig-14"></a>
<pre><code>
hashA = entityA._roId + ':' + entityB._roId;
hashB = entityB._roId + ':' + entityA._roId;
if( !checked[hashA] && !checked[hashB] ){
// mark this pair as checked
checked[hashA] = checked[hashB] = true;
if( this.aabb2DIntersection( entityA, entityB ) ){
pairs.push( [entityA, entityB] );
}
}
</code></pre>
<figcaption>
Fig. 14: Keeping a cache of tested pairs.
</figcaption>
</figure>Maruku只是完全不能解析这个块,而RDiscount使用figure作为html标记,但又认为里面的所有东西都是代码,因为它是缩进的。我假设这是因为支持在html块中解析标记。
在RDiscount或Maruku中,是否存在在html块中禁用解析的方法?
编辑::
事实证明,这个错误,至少在Maruku,是我的错。&和<需要转义,即使在<code>元素中也是如此。所以,虽然我对这个实际的问题还没有答案,但我确实有一个答案,为什么maruku在这个街区有问题。
发布于 2012-10-12 15:10:11
看起来这对Maruku:https://github.com/bhollis/maruku/issues/57#issuecomment-9366049来说是不可能的
https://stackoverflow.com/questions/12667492
复制相似问题