正常登录使用不会出错. 点刷新就报错 ,无页面,
各位判断一般是什么情况造成的.
自己写的出错好找, 内部错了,很晕
控制台出错信息
[Vue warn]: Unhandled error during execution of setup function
at ref=Ref< undefined > >
at
at runtime-core.esm-bundler.js:38:16
[Vue warn]: Unhandled error during execution of scheduler flush. This is likely a Vue internals bug. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/core
at ref=Ref< undefined > >
at
at runtime-core.esm-bundler.js:38:16
[Vue warn]: Unhandled error during execution of watcher callback
at ref=Ref< undefined > >
at
at runtime-core.esm-bundler.js:38:16
Uncaught (in promise) TypeError: vnode is null
setVarsOnVNode runtime-dom.esm-bundler.js:726
setVars runtime-dom.esm-bundler.js:717
callWithErrorHandling runtime-core.esm-bundler.js:155
callWithAsyncErrorHandling runtime-core.esm-bundler.js:164
getter runtime-core.esm-bundler.js:1729
run reactivity.esm-bundler.js:185
flushPostFlushCbs runtime-core.esm-bundler.js:358
flushJobs runtime-core.esm-bundler.js:403
网页出错的内部原码,不是自己写的
function warn(msg, ...args) {
// avoid props formatting or warn handler tracking deps that might be mutated
// during patch, leading to infinite recursion.
pauseTracking();
const instance = stack.length ? stack[stack.length - 1].component : null;
const appWarnHandler = instance && instance.appContext.config.warnHandler;
const trace = getComponentTrace();
if (appWarnHandler) { //
callWithErrorHandling(appWarnHandler, instance, 11 /* APP_WARN_HANDLER */, [
msg + args.join(''),
instance && instance.proxy,
trace
.map(({ vnode }) => `at <${formatComponentName(instance, vnode.type)}>`)
.join('\n'),
trace
]);
}
else { // 可能是这里,但没明白意思
const warnArgs = [`[Vue warn]: ${msg}`, ...args];
/* istanbul ignore if */
if (trace.length &&
// avoid spamming console during tests
!false) {
warnArgs.push(`\n`, ...formatTrace(trace));
}
console.warn(...warnArgs);
}
resetTracking();
}
并不是人家内部错,还是你写的东西有问题呀
这个错误有很多原因的,其中一个你参考下面这个:
https://zhangyu.blog.csdn.net/article/details/112599854