]> git.ipfire.org Git - thirdparty/vuejs/router.git/commitdiff
fix(history): make properties enumerable
authorEduardo San Martin Morote <posva13@gmail.com>
Sun, 2 May 2021 16:16:27 +0000 (18:16 +0200)
committerEduardo San Martin Morote <posva13@gmail.com>
Sun, 2 May 2021 16:16:57 +0000 (18:16 +0200)
src/history/html5.ts
src/history/memory.ts

index c17dc08b1b8b13887d5e19c4cb367fb4c441bef7..3b4c8be38585a085499b95e62cdd2d53e337de2c 100644 (file)
@@ -333,10 +333,12 @@ export function createWebHistory(base?: string): RouterHistory {
   )
 
   Object.defineProperty(routerHistory, 'location', {
+    enumerable: true,
     get: () => historyNavigation.location.value,
   })
 
   Object.defineProperty(routerHistory, 'state', {
+    enumerable: true,
     get: () => historyNavigation.state.value,
   })
 
index f3dfec60f9a057affb70c181609a583c2a00097c..4187cf77122aafd907099611d55804e68b625015 100644 (file)
@@ -95,6 +95,7 @@ export function createMemoryHistory(base: string = ''): RouterHistory {
   }
 
   Object.defineProperty(routerHistory, 'location', {
+    enumerable: true,
     get: () => queue[position],
   })