Description
Vue version
3.5
Link to minimal reproduction
Steps to reproduce
After this change, more hydration mismatch errors are appearing in production. However, Vue's error handlers are unable to catch them, likely because console.error is used directly instead of handleError.
Additionally, it would be helpful if these errors logged more contextual information rather than just a plain string, making debugging easier.
In the provided reproduction link, I introduced a random ID to force a hydration mismatch. However, Vue's error handler does not catch it. I also tested with app.config.errorHandler, but the issue persists.
What is expected?
Vue’s error handlers (onErrorCaptured and app.config.errorHandler) should be able to catch hydration mismatch errors, but they currently cannot, likely because console.error is used directly instead of handleError. Logging these errors through handleError would ensure they are properly intercepted, making it possible to handle them and provide better debugging insights.
What is actually happening?
Debugging becomes harder since it's just an string.
System Info
Any additional comments?
No response