mirror of
https://github.com/nuxt/nuxt.git
synced 2025-02-19 23:21:09 +00:00
prevent error page blinking for user
This commit is contained in:
parent
984031438c
commit
4a7945e7f4
@ -147,6 +147,7 @@ async function loadAsyncComponents (to, from, next) {
|
|||||||
// This may be due to a new deployment or a network problem
|
// This may be due to a new deployment or a network problem
|
||||||
if (/^Loading chunk (\d)+ failed\./.test(message)) {
|
if (/^Loading chunk (\d)+ failed\./.test(message)) {
|
||||||
window.location.reload(true /* skip cache */)
|
window.location.reload(true /* skip cache */)
|
||||||
|
return // prevent error page blinking for user
|
||||||
}
|
}
|
||||||
|
|
||||||
this.error({ statusCode, message })
|
this.error({ statusCode, message })
|
||||||
|
Loading…
Reference in New Issue
Block a user