Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/akshays-repo/mui-react-dialog-alert
https://github.com/akshays-repo/mui-react-dialog-alert
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/akshays-repo/mui-react-dialog-alert
- Owner: akshays-repo
- Created: 2022-07-17T14:40:00.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2022-07-17T14:40:09.000Z (over 2 years ago)
- Last Synced: 2024-10-08T14:43:08.131Z (3 months ago)
- Language: TypeScript
- Size: 108 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# mui-react-alert
An Better way to call mui alert dialog
## Installation
Install mui-react-alert with npm
```bash
npm i mui-react-alert
```## Demo
## Usage/Examples
App.tsx
```javascript
import { AlertDialog } from "mui-react-alert";function App() {
return (
);
}export default App;
```
Button.tsx
```javascript
import { showAlertConfirmarion } from "mui-react-alert";function Button() {
return (
{
showAlertConfirmarion({
title: "Use Google's location service?",
cancelLabel: "DISAGREE",
confirmLabel: "AGREE",
subtitle:
"Let Google help apps determine location. This means sending anonymous location data to Google, even when no apps are running.",
onConfirmation: function (): void {
alert("Say hello");
},
});
}}
>
Show alert dialog
);
}export default Button;
```
## Contributing
Contributions are always welcome!
## Support
For support, email [email protected]