как выставовать, и-конфирм-Message-Before-Delete

var result = confirm("Want to delete?");
if (result) {
    //Logic to delete the item
}
Silly Snake