alertonleave
v1.0.4
Published
Alert on leave
Readme
Install
npm install alertonleave --saveUse
import {alertOnLeave} from "alertonleave";
const dispose = alertOnLeave(()=>{
if (someCondition) {
return "Are you sure you want to leave?"
}
});
// When you don't want to check anymore
dispose();Build with TypeScript 🌹
