diff --git a/packages/app/src/router.jsx b/packages/app/src/router.jsx index 6e767883..31b3df25 100755 --- a/packages/app/src/router.jsx +++ b/packages/app/src/router.jsx @@ -160,6 +160,8 @@ export const PageRender = React.memo((props) => { state, }) + app.location.lastPathname = app.location.pathname + if (state.transitionDelay >= 100) { await new Promise((resolve) => { setTimeout(() => { @@ -172,6 +174,12 @@ export const PageRender = React.memo((props) => { state }) } + + app.backLocation = (state = {}) => { + return navigate(app.location.lastPathname, { + state + }) + } }, []) return