feat: allow pages to override window.history.length (#17742)

* fix: allow pages to override window.history.length

* Update lib/renderer/window-setup.ts

Co-Authored-By: magne4000 <joel.charles91@gmail.com>

* fix: lint error
This commit is contained in:
Joël Charles 2019-12-16 03:14:28 +01:00 committed by Cheng Zhao
parent 6a03d3cc66
commit 0bcfae752e

View file

@ -242,7 +242,8 @@ export const windowSetup = (
Object.defineProperty(window.history, 'length', {
get: function () {
return ipcRendererInternal.sendSync('ELECTRON_NAVIGATION_CONTROLLER_LENGTH')
}
},
set () {}
})
if (guestInstanceId != null) {