We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b400160 commit f241654Copy full SHA for f241654
src/runtime/plugin.nuxt2.client.ts
@@ -10,7 +10,7 @@ const sendVitals = to => webVitals({
10
})
11
12
export default function (ctx) {
13
- const router = ctx.app?.router || ctx.$router
+ const router = (ctx.app && ctx.app.router) || ctx.$router
14
if (!router) { return }
15
router.onReady((to) => {
16
sendVitals(to)
0 commit comments