Bootstrap允许您以两种不同的键方式显示代码 :
第一种是< code>标签.如果您要以内联方式显示代码,则应使用< code>标签.
其次是< pre>标签.如果代码需要显示为独立的块元素,或者它有多行,那么你应该使用< pre>标签.
确保在使用< pre>时和<代码>标签,你使用unicode变体打开和关闭标签 : & lt; 和& gt; .
让我们看一下下面的示例 :
<header>
is wrapped as an inline element.To display code as a standalone block element use <pre> tag as:
<article> <h1>Article Heading</h1> </article>