 <span class="k">@include</span> <span class="nd">clearfix</span><span class="p">;</span>
<span class="p">}</span></code></pre></figure>

<p>以下示例显示了如何使用clearfix。 不使用clearfix，外层div将不会包裹按钮而导致布局损坏。</p>

<div class="bd-example">
<div class="bg-info clearfix">
  <button type="button" class="btn btn-secondary float-left">Example Button floated left</button>
  <button type="button" class="btn btn-secondary float-right">Example Button floated right</