0👍
✅
try
if(!user)
{
next({
path: '/auth'
})
}
instead of
if (!user) {
next('/auth');
}
Source:stackexchange.com