@bscop/react-tabs
TypeScript icon, indicating that this package has built-in type declarations

1.0.6 • Public • Published

react-tabs

GitHub license npm version CircleCI Status Coverage

Accessible tabs (in React).

View in Storybook.

Install

npm i @bscop/react-tabs

Usage

import Tabs from "@bscop/react-tabs";

function App () {
  return (
    <Tabs 
      tabs={[
        {
          id: "tab-1",
          label: "Section one",
          renderContent () {
            return (
              <p>Content of the first tab ...</p>
            );
          },
        },
        {
          id: "tab-2",
          label: "Section two",
          renderContent () {
            return (
              <p>Content of the second tab ...</p>
            );
          },
        }
      ]}
      title="Switch tab"
    />
  );
}

Contribute

Read the guidelines.

Run tests

npm test

Coverage

Coverage reports are hosted on codecov.

npm run badge:coverage -- --token=<guid>

Bruno Scopelliti
www.brunoscopelliti.com

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.6
    2
    • latest

Version History

Package Sidebar

Install

npm i @bscop/react-tabs

Weekly Downloads

2

Version

1.0.6

License

MIT

Unpacked Size

45.8 kB

Total Files

11

Last publish

Collaborators

  • brunoscopelliti