File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change 1+ import { isEqual } from 'lodash-es'
12import { decryptHistory , encryptHistory , historySessionStorageKeys } from './encryption'
23import { page as currentPage } from './page'
34import Queue from './queue'
@@ -106,6 +107,10 @@ class History {
106107 return
107108 }
108109
110+ if ( isEqual ( this . getScrollRegions ( ) , scrollRegions ) ) {
111+ return
112+ }
113+
109114 return this . doReplaceState ( {
110115 page : window . history . state . page ,
111116 scrollRegions,
@@ -121,6 +126,10 @@ class History {
121126 return
122127 }
123128
129+ if ( isEqual ( this . getDocumentScrollPosition ( ) , scrollRegion ) ) {
130+ return
131+ }
132+
124133 return this . doReplaceState ( {
125134 page : window . history . state . page ,
126135 documentScrollPosition : scrollRegion ,
You can’t perform that action at this time.
0 commit comments