Skip to content

Bug: Can't really access component stack errorInfo.componentStack on server #35349

@brillout

Description

@brillout

React version: 19.2.2

On the server-side, upon a boundary error, the component stack can be accessed via onError(err, errorInfo) => errorInfo.componentStack but this has limited (no?) value because the general recommendation is to swallow boundary errors and let the client-side throw the error instead (if it fails again on the client-side).

The real value AFAICT would be to access the component stack upon shell errors, but I don't see a way to access error.componentStack:

Context

I'm the author of react-streaming which powers vike-react amongst others.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: UnconfirmedA potential issue that we haven't yet confirmed as a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions