react-confirm-btn

1.1.1 • Public • Published

React Confirm Button

Simple react component that handles confirmation before running an action

Installation

npm install react-confirm-btn --save
// or
yarn add react-confirm-btn

Example

import ConfirmBtn from 'react-confirm-btn'

...
<ConfirmBtn onConfirm="..." > Delete </ConfirmBtn>

Props


{
    onConfirm: () => void,
    confirmText?: string,
    time?: number,
    style?: {},
    ...
}

Demo

Check out the Demo generated using storybook

Package Sidebar

Install

npm i react-confirm-btn

Weekly Downloads

9

Version

1.1.1

License

MIT

Last publish

Collaborators

  • ahoseinian