mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-01-31 20:03:37 +00:00
fix(ui): restore startup project context
This commit is contained in:
@@ -3,9 +3,10 @@ import { routeTree } from '../routeTree.gen';
|
||||
|
||||
// Use browser history in web mode (for e2e tests and dev), memory history in Electron
|
||||
const isElectron = typeof window !== 'undefined' && window.electronAPI !== undefined;
|
||||
const BOARD_ROUTE_PATH = '/board';
|
||||
|
||||
const history = isElectron
|
||||
? createMemoryHistory({ initialEntries: [window.location.pathname || '/'] })
|
||||
? createMemoryHistory({ initialEntries: [BOARD_ROUTE_PATH] })
|
||||
: createBrowserHistory();
|
||||
|
||||
export const router = createRouter({
|
||||
|
||||
Reference in New Issue
Block a user