Made with create-react-library
npm install --save @cc-test2/alert
import React, { Component } from 'react'
import Alert from '@cc-test2/alert'
const AlertComponent = () => {
const {isOpen, onOpen, onClose} = useDisclosure();
return (
<>
<Button size='xs' onClick={onOpen}>Open Alert</Button>
<Alert
title='Delete Access'
body="Are you sure? You can't undo this action afterwards."
isOpen={isOpen}
onClose={onClose}
handleAction={()=>alert("Hello")}/>
</>))
}
MIT © CodeCraft