s72
  • Code tabs

    data-tabs since 0.1.0

    One job written for several tools: npm, pnpm, cargo. A <figure data-tabs> holding a run of <pre> shows one at a time, under a row of tabs.

    Basic

    npm i s72
    pnpm add s72
    cargo add s72
    html
    <figure data-tabs>
      <pre data-lang="sh" data-title="npm"><code>npm i s72</code></pre>
      <pre data-lang="sh" data-title="pnpm"><code>pnpm add s72</code></pre>
      <pre data-lang="sh" data-title="cargo"><code>cargo add s72</code></pre>
    </figure>

    data-title names the tab. Leave it out and the tab takes the block's data-lang.

    Notes