Evitar el historial de regreso JavaScript
// There are numerous reasons why disabling the back button will not really work. Your best bet is to warn the user:
window.onbeforeunload = function() { return "Your work will be lost."; };
https://aybee.codes