globalHistory.pushState function excuted failed in baidu.app
Author: zhaohongyanCreated May 2, 2022Updated Aug 1, 2025
https://github.com/remix-run/history/blob/dev/packages/history/index.ts line497 I encountered a compatibility problem. When using Baidu app, the page could not be jumped. After debugging, it was found that the globalHistory.pushState method was not executed or failed to execute. Other browsers do not have this problem.
<BrowserRouter>
<Routes>
<Route path="/" element={<Home />} />
<Route path="/about" element={<About />} />
<Route path="/page" element={<Page />} />
</Routes>
</BrowserRouter>
Source: remix-run/history