“SweetAlert2” Ответ

SweetAlert2

$ npm install sweetalert2
Elegant Eel

SweetAlert2

npm install sweetalert2
Scary Salamander

SweetAlert2

Swal.fire(
  'Data Add Successfully!',
  'You clicked the button!',
  'success'
)
Graceful Goose

SweetAlert2

Swal.fire(
  'Good job!',
  'You clicked the button!',
  'failed'
)
Wrong Worm

SweetAlert2

Swal.fire({
  title: '<strong>HTML <u>example</u></strong>',
  icon: 'info',
  html:
    'You ccccc can use <b>bold text</b>, ' +
    '<a href="//sweetalert2.github.io">links</a> ' +
    'and other HTML tags',
  showCloseButton: true,
  showCancelButton: true,
  focusConfirm: false,
  confirmButtonText:
    '<i class="fa fa-thumbs-up"></i> Great!',
  confirmButtonAriaLabel: 'Thumbs up, great!',
  cancelButtonText:
    '<i class="fa fa-thumbs-down"></i>',
  cancelButtonAriaLabel: 'Thumbs down'
})
Marlon Sab-a

SweetAlert2

const Toast = Swal.mixin({
  toast: true,
  position: 'top-end',
  showConfirmButton: false,
  timer: 3000,
  timerProgressBar: true,
  didOpen: (toast) => {
    toast.addEventListener('mouseenter', Swal.stopTimer)
    toast.addEventListener('mouseleave', Swal.resumeTimer)
  }
})

Toast.fire({
  icon: 'success',
  title: 'Signed in successfully'
})
Samir Amegroud

SweetAlert2

const { value: email } = await Swal.fire({  title: 'Input email address',  input: 'email',  inputLabel: 'Your email address',  inputPlaceholder: 'Enter your email address'})if (email) {  Swal.fire(`Entered email: ${email}`)}
Thoughtless Tarantula

SweetAlert2

Best alert library in javascript for me
:)
Fair Flatworm

SweetAlert2

npm install sweetalert2 --save
Thankful Tamarin

Ответы похожие на “SweetAlert2”

Смотреть популярные ответы по языку

Смотреть другие языки программирования