history.pushState(null, null, '#');window.addEventListener('popstate', function(event) {// 点击回退时再向历史记录插入一条, 以便阻止下一次点击回退history.pushState(null, null, '#' );});
来源: http://www.qdfuns.com/article/37318/04e4a01183dd3cad6724dfae91a07b0c.html