🔔 Alert..!! Get 2 Month Free Cloud Hosting With $200 Bonus From Digital Ocean ACTIVATE DEAL

A react component used for creating SweetAlert style elegant alert message popups.

Modal_Popup React Native

Documentation

react-simplert

License Github Issue GitHub Fork GitHub Star

version downloads monthly downloads

react-simplert

ReactJS Simple Alert Component (SweetAlert Inspired)

Demo

https://mazipan.github.io/react-simplert/

Download

npm install react-simplert OR yarn add react-simplert 

How to Use

Import to your component :

import Simplert from 'react-simplert'

Create some template in render() :

<Simplert      showSimplert={ this.state.showAlert }     type={ this.state.typeAlert }     title={ this.state.titleAlert }     message={ this.state.messageAlert } />

Just set the props with your custom state.

Available Props

{   showSimplert: PropTypes.bool.isRequired,   title: PropTypes.string,   message: PropTypes.any,           type: PropTypes.string,   customClass: PropTypes.string,   customIconUrl: PropTypes.string,   onOpen: PropTypes.func,   customCloseBtnText: PropTypes.string,   customCloseBtnClass: PropTypes.string,   onClose: PropTypes.func,   onOverlayClose: PropTypes.func,   useConfirmBtn: PropTypes.bool,   customConfirmBtnText: PropTypes.string,   customConfirmBtnClass: PropTypes.string,   onConfirm: PropTypes.func,   disableOverlayClick: PropTypes.bool,   hideAllButton: PropTypes.bool }

Note: If onClose is provided but onOverlayClose is not, onClose will be called when the Simplert is closed via the overlay.

Hope will usefull for you all.

Contact Me :

Email Website Facebook

Twitter Linkedin Slideshare


You May Also Like