Skip to content

Commit 1a2766b

Browse files
committed
refactor: state typ
1 parent 941b213 commit 1a2766b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/router/src/router.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -938,7 +938,7 @@ export function createRouter(options: RouterOptions): Router {
938938

939939
// only consider as push if it's not the first navigation
940940
const isFirstNavigation = from === START_LOCATION_NORMALIZED
941-
const state = !isBrowser ? {} : history.state
941+
const state: Partial<HistoryState> | null = !isBrowser ? {} : history.state
942942

943943
// change URL only if the user did a push/replace and if it's not the initial navigation because
944944
// it's just reflecting the url

0 commit comments

Comments
 (0)