Open KhantMhueZawWin opened 6 months ago
function deleteNote(noteId) { console.log('deleteNote function called with noteId:', noteId); fetch("/delete-note", { method: "POST", body: JSON.stringify({ noteId: noteId }), }).then((_res) => { window.location.href = "/"; }); }
i tried adding console.log in js nothing happens
function deleteNote(noteId) { console.log('deleteNote function called with noteId:', noteId); fetch("/delete-note", { method: "POST", body: JSON.stringify({ noteId: noteId }), }).then((_res) => { window.location.href = "/"; }); }
i tried adding console.log in js nothing happens