https://github.com/malcodeman/react-button-group
A button group is a set of two or more button segments.
https://github.com/malcodeman/react-button-group
button button-group react
Last synced: 3 months ago
JSON representation
A button group is a set of two or more button segments.
- Host: GitHub
- URL: https://github.com/malcodeman/react-button-group
- Owner: malcodeman
- License: mit
- Created: 2020-05-13T15:14:52.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T05:49:57.000Z (over 2 years ago)
- Last Synced: 2025-03-18T04:47:58.994Z (3 months ago)
- Topics: button, button-group, react
- Language: JavaScript
- Homepage: http://react-button-group-storybook.surge.sh/
- Size: 4.61 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 23
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- my-awesome-repos - react-button-group - A button group is a set of two or more button segments. (Packages)
README
# [react-button-group](http://react-button-group-storybook.surge.sh)
[](https://github.com/malcodeman/react-button-group/blob/master/LICENSE)
[](https://www.npmjs.com/package/@malcodeman/react-button-group)
[](https://github.com/prettier/prettier)A button group is a set of two or more button segments. Within the control, all segments are equal in width. A button group is often used to switch between views of some data.
## Getting started
```sh
yarn add @malcodeman/react-button-group
# or
npm install --save @malcodeman/react-button-group
``````jsx
import React from "react";
import { ButtonGroup } from "@malcodeman/react-button-group";function App() {
const [selected, setSelected] = React.useState([0]);return (
{
setSelected([index]);
}}
>
One
Two
Three
);
}export default App;
```## License
[MIT](./LICENSE)