0
<div class="section-container accordion" data-section="accordion">
  <section class="active">
    <p class="title" data-section-title><a href="#">Section 1</a></p>
    <div class="content" data-section-content>
      <p>Content of section 1.</p>
    </div>
  </section>
  <section>
    <p class="title" data-section-title><a href="#">Section 2</a></p>
    <div class="content" data-section-content>
      <p>Content of section 2.</p>
    </div>
  </section>
</div>

そのコード ブロックの 4 行目にランダムな data-section-content (from here ) があり、私の IDE はそれを嫌うようです。何のために?

4

1 に答える 1

1

属性「data-section-content」は、アクティブなタブに応じて非表示/表示されるコンテンツを表します。ほとんどの場合、IDE は HTML5 属性をサポートしていないため、xhtml のように定義する必要があります: data-section-content="data-section-content"

于 2013-10-30T16:08:50.543 に答える