Overview Official Website
A beautiful, responsive, customizable, accessible (WAI-ARIA) replacement for JavaScript's popup boxes.
Add Package
yarn add sweetalert2
Import Package
import Swal from 'sweetalert2';
Remove Package
yarn remove sweetalert2 (or you can remove package by removing specific package from
package.json )
Examples:
Title | Vue |
---|---|
A Basic Message |
|
A Title with a Text Under |
|
A Success message! |
|
A warning message, with a function attached to the 'Confirm' button... |
|
By passing a parameter, you can execute something else for 'Cancel'. |
|
A message with a custom Image Header |
|
A message with auto close timer |
|
Custom HTML description and buttons |
|
A custom positioned dialog |
|
A message with custom width, padding, and background |
|
Ajax request example |
|
Dynamic queue example |
|