Skip to content

Commit 68c2700

Browse files
committed
fix(nuxt): add additional logging when skipping error page for bot
1 parent 2d8d859 commit 68c2700

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

packages/nuxt/src/app/components/nuxt-root.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ const BOT_RE = /bot\b|chrome-lighthouse|facebookexternalhit|google\b|googlebot/i
6060
onErrorCaptured((err, target, info) => {
6161
nuxtApp.hooks.callHook('vue:error', err, target, info).catch(hookError => console.error('[nuxt] Error in `vue:error` hook', hookError))
6262
if (import.meta.client && BOT_RE.test(navigator.userAgent)) {
63+
nuxtApp.hooks.callHook('app:error', err)
64+
console.error(`[nuxt] Not rendering error page for bot with user agent \`${navigator.userAgent}\`:`, err)
6365
return false
6466
}
6567
if (import.meta.server || (isNuxtError(err) && (err.fatal || err.unhandled))) {

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy