Skip to content

Angular 22 support #738

Description

@ilyakonrad

Angular 22 has been out for a month now, but Stream Chat Angular still doesn't support it. Error when opening a channel:

ERROR Error: ASSERTION ERROR: token must be defined [Expected=> null != undefined <=Actual]

Image

Verified by Claude:

Root cause — confirmed Angular 22 fallout. Angular 22 removed the long-deprecated ComponentFactoryResolver export from @angular/core, and two chat dependencies still inject it:

stream-chat-angular@7.1.4MessageInputComponent
angular-mentions@1.5.0MentionDirective (used inside the message input's autocomplete textarea)

Their compiled factories reference i0.ComponentFactoryResolver, which is now undefined, so opening a chat throws ASSERTION ERROR: token must be defined in ɵɵdirectiveInject while Angular is instantiating the message view. The @if (activeChannel$ | async) embedded view aborts mid-creation, leaving the right pane blank — exactly the "white screen when accessing chat history" in the ticket. I reproduced it in the browser against staging (channel list rendered, clicking any chat gave a white pane; in some runs the repeated error cycle even froze the tab), and confirmed the errors in the console.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions