@pinnacle0/react-stack-router
Advanced tools
Comparing version 0.1.3-beta.45 to 0.1.3-beta.46
@@ -36,3 +36,3 @@ import { Route } from "../route"; | ||
push(to: To, option?: PushOption): Promise<void>; | ||
pop(times?: number): Promise<void>; | ||
pop(t?: number): Promise<void>; | ||
replace(to: To, state?: Record<string, any>): void; | ||
@@ -39,0 +39,0 @@ replaceSearchParams<T extends Record<string, string> = Record<string, string>>(newParam: T | ((current: T) => T)): void; |
@@ -69,4 +69,5 @@ import { Action } from "history"; | ||
} | ||
async pop(times = 1) { | ||
if (times === 0) | ||
async pop(t) { | ||
const times = typeof t === "number" ? t : 1; | ||
if (times <= 0) | ||
return; | ||
@@ -73,0 +74,0 @@ let wait; |
{ | ||
"name": "@pinnacle0/react-stack-router", | ||
"version": "0.1.3-beta.45", | ||
"version": "0.1.3-beta.46", | ||
"author": "Pinnacle", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
@@ -116,4 +116,5 @@ import {Action} from "history"; | ||
async pop(times: number = 1): Promise<void> { | ||
if (times === 0) return; | ||
async pop(t?: number): Promise<void> { | ||
const times = typeof t === "number" ? t : 1; | ||
if (times <= 0) return; | ||
@@ -120,0 +121,0 @@ let wait!: Promise<void>; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
161171
2517