Skip to content

Commit

Permalink
Fix failing tests from #18372
Browse files Browse the repository at this point in the history
  • Loading branch information
tgriesser committed Oct 8, 2021
1 parent a8b43ee commit 5e01320
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions packages/app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"cypress:launch": "cross-env TZ=America/New_York node ../../scripts/cypress open --project ${PWD}",
"cypress:open": "yarn gulp cyOpenAppE2E",
"cypress:run:e2e": "yarn gulp cyRunAppE2E",
"debug": "gulp debug --project ${PWD}",
"dev": "gulp dev --project ${PWD}",
"start": "echo \"run 'yarn dev' from the root\" && exit 1",
"watch": "echo \"run 'yarn dev' from the root\" && exit 1",
Expand Down
5 changes: 4 additions & 1 deletion packages/app/src/router/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@ import { setupLayouts } from 'virtual:generated-layouts'
export const createRouter = () => {
const routes = setupLayouts(generatedRoutes)

// TODO: clean this up
const historyBase = window.location.href.includes('__vite__') ? '__vite__' : ''

return _createRouter({
history: createWebHistory('/__vite__/'),
history: createWebHistory(historyBase),
routes,
})
}

0 comments on commit 5e01320

Please sign in to comment.