You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After setting vueRouterMode: 'history' in quasar.config, the SPA runs correctly in history mode. However, in Android Capacitor mode, the URL still falls back to hash mode.
While debugging with the Android WebView plugin in VS Code, I found that process.env.VUE_ROUTER_MODE is not set to history in Capacitor mode. As a result, the router defaults to createWebHashHistory in the defineRouter function inside router/index.ts.
What did you expect to happen?
process.env.VUE_ROUTER_MODE should be set to history as configured in quasar.config, so that the router uses history mode in Capacitor as well.
Reproduction URL
Note: The issue only occurs in Capacitor mode.
How to reproduce?
Set vueRouterMode: 'history' in quasar.config.
Run the app in Capacitor mode.
Use the remote debugger.
Observe that process.env.VUE_ROUTER_MODE is set to hash instead of history.
Flavour
Quasar CLI with Vite (@quasar/cli | @quasar/app-vite)