swal({title: "Good job", text: "You clicked the button!", type: "success"}).then(function(){ location.reload(); } );
swal({ title: "Good job", text: "You clicked the button!", icon: "success", buttons: [ 'NO', 'YES' ], }).then(function(isConfirm) { if (isConfirm) { location.reload(); } else { //if no clicked => do something else } });
swal({title: "Good job", text: "You clicked the button!", type: "success"}, function(){ location.reload(); } );